Update pipenv lockfile (#392) #89
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: deploy | |
| on: | |
| push: | |
| branches: | |
| - main | |
| paths: | |
| - "src/**" | |
| - "Pipfile*" | |
| - "serverless/serverless.yml" | |
| workflow_dispatch: | |
| inputs: | |
| stage: | |
| description: "Deployment stage" | |
| required: false | |
| default: "test" | |
| type: choice | |
| options: | |
| - test | |
| - prod | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event.inputs.stage }} | |
| cancel-in-progress: true | |
| env: | |
| NO_UPDATE_NOTIFIER: true | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-latest | |
| environment: AWS-${{ github.event.inputs.stage || 'test' }} | |
| permissions: | |
| id-token: write | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0 | |
| with: | |
| python-version: "3.14" | |
| architecture: "x64" | |
| cache: "pipenv" | |
| cache-dependency-path: Pipfile.lock | |
| - name: Install pipenv | |
| run: pip install --prefer-binary -r requirements.txt | |
| - name: Create requirements | |
| run: pipenv requirements > ${{ github.workspace }}/serverless/requirements.txt | |
| - uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0 | |
| with: | |
| node-version: 24 | |
| cache: "npm" | |
| cache-dependency-path: serverless/package-lock.json | |
| - name: Install dependencies | |
| run: npm ci --ignore-scripts | |
| working-directory: ./serverless | |
| - name: Configure AWS Credentials | |
| uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0 | |
| with: | |
| aws-region: ${{ vars.AWS_REGION }} | |
| role-to-assume: ${{ secrets.AWS_ROLE }} | |
| - name: Deploy ${{ github.event.inputs.stage || 'test' }} | |
| run: npm run deploy -- --stage ${{ github.event.inputs.stage || 'test' }} | |
| working-directory: ./serverless | |
| env: | |
| SLS_AWS_SDK: ${{ vars.SLS_AWS_SDK_VERSION }} | |
| SERVERLESS_LICENSE_KEY: ${{ secrets.SERVERLESS_LICENSE_KEY }} | |
| SERVERLESS_BUCKET: ${{ secrets.SERVERLESS_BUCKET }} | |
| GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }} | |
| OPENWEATHER_API_KEY: ${{ secrets.OPENWEATHER_API_KEY }} | |
| TELEGRAM_TOKEN: ${{ secrets.TELEGRAM_TOKEN }} | |
| F1_CALENDAR_URL: ${{ vars.F1_CALENDAR_URL }} |