Skip to content

Tweak how we set GOTOOLCHAIN #2

Tweak how we set GOTOOLCHAIN

Tweak how we set GOTOOLCHAIN #2

name: Go Build and Deploy
on:
workflow_dispatch:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.20' # We'll use this to install the RC
- name: Install Go RC
run: |
go install golang.org/dl/go1.23rc1@latest
go1.23rc1 download
- name: Build
run: go build -v ./...
env:
GOTOOLCHAIN: go1.23rc1
- name: Run
run: ./your-executable-name
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-east-1 # Replace with your AWS region
- name: Upload to S3
run: ./upload.sh