fix: use generate content #97
This file contains 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
on: | |
push: | |
branches: | |
- main | |
env: | |
ARCH: GOARCH=arm64 | |
jobs: | |
build-deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v4 | |
with: | |
go-version: '^1.21.5' | |
check-latest: true | |
- uses: aws-actions/setup-sam@v2 | |
with: | |
use-installer: true | |
- uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
aws-region: us-east-1 | |
- run: go test ./... -race -coverprofile=coverage.out -covermode=atomic | |
- uses: codecov/codecov-action@v3 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
verbose: true | |
- run: sam build --parameter-overrides Runtime=provided.al2 Handler=bootstrap Architecture=arm64 ApiKey=${{ secrets.OPENAI_API_KEY }} | |
- run: sam deploy --stack-name chat-gpt --s3-bucket ${{ secrets.S3_BUCKET }} --parameter-overrides Runtime=provided.al2 Handler=bootstrap Architecture=arm64 GptApiKey=${{ secrets.OPENAI_API_KEY }} GeminiApiKey=${{ secrets.GEMINI_API_KEY }} --capabilities CAPABILITY_IAM |