Deploy #162
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
name: Deploy | |
on: workflow_dispatch | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v1 | |
with: | |
dotnet-version: 6.0.x | |
- name: Build Estbot | |
run: dotnet publish src/Automation/Estranged.Automation.csproj --configuration Release --runtime linux-x64 --output build/output | |
- name: Login to Public ECR | |
uses: docker/login-action@v1 | |
with: | |
registry: public.ecr.aws | |
username: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
password: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
- name: Push to ECR | |
env: | |
IMAGE_TAG: ${{ github.sha }} | |
run: | | |
docker build -t public.ecr.aws/j7m3k0v4/estbot:$IMAGE_TAG . | |
docker build -t public.ecr.aws/j7m3k0v4/estbot:latest . | |
docker push --all-tags public.ecr.aws/j7m3k0v4/estbot |