temporary fixes to get the sample app running #87
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: LocalStack CI | |
| on: | |
| push: | |
| paths-ignore: | |
| - 'README.md' | |
| branches: | |
| - main | |
| pull_request: | |
| branches: | |
| - main | |
| schedule: | |
| # “At 00:00 on Sunday.” | |
| - cron: "0 0 * * 0" | |
| workflow_dispatch: | |
| jobs: | |
| deploy-snowflake: | |
| name: Deploy to Snowflake emulator | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.12' | |
| - name: Install Snow CLI | |
| run: | | |
| pip install snowflake-cli==3.7.2 | |
| snow --version | |
| snow connection add \ | |
| --connection-name localstack \ | |
| --user test \ | |
| --password test \ | |
| --account test \ | |
| --role test \ | |
| --warehouse test \ | |
| --database test \ | |
| --schema test \ | |
| --port 4566 \ | |
| --host snowflake.localhost.localstack.cloud \ | |
| --no-interactive | |
| snow connection list | |
| - name: Start LocalStack | |
| uses: LocalStack/setup-localstack@v0.2.4 | |
| with: | |
| image-tag: 'latest' | |
| use-pro: 'true' | |
| configuration: LS_LOG=trace | |
| install-awslocal: 'true' | |
| env: | |
| IMAGE_NAME: localstack/snowflake:latest | |
| LOCALSTACK_AUTH_TOKEN: ${{ secrets.LOCALSTACK_AUTH_TOKEN }} | |
| - name: Install dependencies | |
| run: | | |
| make install | |
| - name: Create Snowflake resources | |
| run: | | |
| make seed | |
| - name: Create AWS resources | |
| run: | | |
| make aws | |
| make upload | |
| - name: Run dbt models | |
| run: | | |
| make dbt | |
| # Native App deployment (`make app`) is temporarily disabled pending a | |
| # LocalStack Snowflake emulator fix - `snow app run` triggers an | |
| # `Unknown function INTERNAL$TO_CHAR` error while creating the | |
| # application package database. Track the upstream issue before | |
| # re-enabling this step. | |
| # - name: Deploy Native App | |
| # run: | | |
| # make app | |
| - name: Run tests | |
| run: | | |
| pip3 install pytest pandas numpy | |
| make test |