Skip to content

Commit

Permalink
fir gh action vars
Browse files Browse the repository at this point in the history
  • Loading branch information
nalbam committed Jun 10, 2024
1 parent b414533 commit 22237b7
Showing 1 changed file with 16 additions and 17 deletions.
33 changes: 16 additions & 17 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,18 @@ on:
- main

env:
BOT_CURSOR: ${{ secrets.BOT_CURSOR }}
ALLOWED_CHANNEL_IDS: ${{ vars.ALLOWED_CHANNEL_IDS }}
BOT_CURSOR: ${{ vars.BOT_CURSOR }}
DYNAMODB_TABLE_NAME: ${{ vars.DYNAMODB_TABLE_NAME }}
ENABLE_IMAGE: ${{ vars.ENABLE_IMAGE }}
IMAGE_MODEL_ID: ${{ vars.IMAGE_MODEL_ID }}
SYSTEM_MESSAGE: ${{ vars.SYSTEM_MESSAGE }}
TEXT_MODEL_ID: ${{ vars.TEXT_MODEL_ID }}

AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
SLACK_SIGNING_SECRET: ${{ secrets.SLACK_SIGNING_SECRET }}
DYNAMODB_TABLE_NAME: ${{ secrets.DYNAMODB_TABLE_NAME }}
TEXT_MODEL_ID: ${{ secrets.TEXT_MODEL_ID }}
IMAGE_MODEL_ID: ${{ secrets.IMAGE_MODEL_ID }}
SYSTEM_MESSAGE: ${{ vars.SYSTEM_MESSAGE }}
ALLOWED_CHANNEL_IDS: ${{ secrets.ALLOWED_CHANNEL_IDS }}
ENABLE_IMAGE: ${{ secrets.ENABLE_IMAGE }}

jobs:
deploy:
Expand Down Expand Up @@ -45,19 +48,15 @@ jobs:

- name: Set up environment variables 📝
run: |
echo "ALLOWED_CHANNEL_IDS=${ALLOWED_CHANNEL_IDS}" >> .env
echo "BOT_CURSOR=${BOT_CURSOR}" >> .env
echo "SLACK_BOT_TOKEN=${SLACK_BOT_TOKEN}" >> .env
echo "SLACK_SIGNING_SECRET=${SLACK_SIGNING_SECRET}" >> .env
echo "DYNAMODB_TABLE_NAME=${DYNAMODB_TABLE_NAME}" >> .env
echo "TEXT_MODEL_ID=${TEXT_MODEL_ID}" >> .env
echo "ENABLE_IMAGE=${ENABLE_IMAGE}" >> .env
echo "IMAGE_MODEL_ID=${IMAGE_MODEL_ID}" >> .env
echo "SLACK_BOT_TOKEN=${SLACK_BOT_TOKEN}" >> .env
echo "SLACK_SIGNING_SECRET=${SLACK_SIGNING_SECRET}" >> .env
echo "SYSTEM_MESSAGE=${SYSTEM_MESSAGE}" >> .env
echo "ALLOWED_CHANNEL_IDS=${ALLOWED_CHANNEL_IDS}" >> .env
echo "ENABLE_IMAGE=${ENABLE_IMAGE}" >> .env
echo "TEXT_MODEL_ID=${TEXT_MODEL_ID}" >> .env
- name: Deploy to AWS Lambda 🚀
env:
AWS_REGION: 'us-east-1'
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
run: npx serverless deploy
run: npx serverless deploy --region us-east-1

0 comments on commit 22237b7

Please sign in to comment.