Skip to content

Commit d50592b

Browse files
peter-smith-phdgtsiolisclaudequetzalliwrites
authored
docs(lstk hotfix): migrate Snowflake CI page from localstack CLI to lstk (#880)
Co-authored-by: George Tsiolis <tsiolis.g@gmail.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Co-authored-by: Quetzalli <hola@quetzalliwrites.com>
1 parent 27b0f05 commit d50592b

1 file changed

Lines changed: 11 additions & 23 deletions

File tree

src/content/docs/snowflake/integrations/continuous-integration.mdx

Lines changed: 11 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { Tabs, TabItem } from '@astrojs/starlight/components';
1010

1111
This guide explains how to set up the Snowflake emulator in a continuous integration (CI) environment. You can use the emulator to test your Snowflake integration without connecting to the real Snowflake instance.
1212

13-
To install the Snowflake emulator, you need to set up the LocalStack CLI and pull the Docker image. After starting the Docker container, an endpoint (`snowflake.localhost.localstack.cloud`) is made available to connect to the emulated Snowflake instance, which you can use to test your data integrations in CI environments.
13+
To install the Snowflake emulator, you need to set up the [`lstk` CLI](/aws/developer-tools/running-localstack/lstk/), which authenticates, pulls the Docker image, and starts the container for you. After starting the Docker container, an endpoint (`snowflake.localhost.localstack.cloud`) is made available to connect to the emulated Snowflake instance, which you can use to test your data integrations in CI environments.
1414

1515
## Configure the LocalStack CI Key
1616

@@ -41,12 +41,9 @@ jobs:
4141
- uses: actions/checkout@v3
4242

4343
- name: Start Snowflake emulator
44-
run:
45-
docker pull localstack/snowflake:latest
46-
pip install localstack
47-
localstack start --stack snowflake -d
48-
echo "Waiting for LocalStack startup..."
49-
localstack wait -t 15
44+
run: |
45+
npm install -g @localstack/lstk
46+
lstk start --type snowflake --timeout 90s
5047
echo "Startup complete"
5148
env:
5249
LOCALSTACK_AUTH_TOKEN: ${{ secrets.LOCALSTACK_AUTH_TOKEN }}
@@ -56,9 +53,6 @@ jobs:
5653
```yaml showLineNumbers
5754
version: 2.1
5855

59-
orbs:
60-
python: circleci/python@2.0.3
61-
6256
jobs:
6357
example-job:
6458
machine:
@@ -68,15 +62,11 @@ jobs:
6862
- checkout
6963

7064
- run:
71-
name: Start LocalStack
65+
name: Start Snowflake emulator
7266
command: |
73-
pip3 install localstack
74-
docker pull localstack/snowflake
75-
localstack start --stack snowflake -d
76-
77-
echo "Waiting for LocalStack startup..."
78-
localstack wait -t 30
79-
echo "Startup complete"
67+
npm install -g @localstack/lstk
68+
lstk start --type snowflake --timeout 90s
69+
echo "Startup complete"
8070
8171
workflows:
8272
version: 2
@@ -106,14 +96,12 @@ test:
10696

10797
before_script:
10898
- apk update
109-
- apk add gcc musl-dev linux-headers py3-pip python3 python3-dev
110-
- python3 -m pip install localstack
99+
- apk add --no-cache nodejs npm
100+
- npm install -g @localstack/lstk
111101
script:
112-
- docker pull localstack/snowflake:latest
113102
- dind_ip="$(getent hosts docker | cut -d' ' -f1)"
114103
- echo "${dind_ip} localhost.localstack.cloud " >> /etc/hosts
115-
- DOCKER_HOST="tcp://${dind_ip}:2375" localstack start --stack snowflake -d
116-
- localstack wait -t 15
104+
- DOCKER_HOST="tcp://${dind_ip}:2375" lstk start --type snowflake --timeout 90s
117105
```
118106
</TabItem>
119107
</Tabs>

0 commit comments

Comments
 (0)