Update Docker Images #120
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: Update Docker Images | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: '50 6 * * 0-6' | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
env: | |
AWS_REGION: us-east-1 | |
jobs: | |
generate-docker-images: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Get day of the week to see if its after hyper-tuesdays | |
id: weekday | |
run: echo "::set-output name=weekday::$(date +'%u')" | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: Login to Docker Hub | |
uses: docker/login-action@v2 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Build and push latest mintter-site | |
uses: docker/build-push-action@v4 | |
with: | |
push: true | |
file: backend/cmd/mintter-site/Dockerfile | |
tags: mintter/mintter-site:latest | |
- name: Build and push stable mintter-site | |
if: ${{ steps.weekday.outputs.weekday == '3' }} | |
uses: docker/build-push-action@v4 | |
with: | |
push: true | |
file: backend/cmd/mintter-site/Dockerfile | |
tags: mintter/mintter-site:stable | |
- name: Build and push latest mintterd | |
uses: docker/build-push-action@v4 | |
with: | |
push: true | |
file: backend/cmd/mintterd/Dockerfile | |
tags: mintter/mintterd:latest | |
- name: Build and push stable mintterd | |
if: ${{ steps.weekday.outputs.weekday == '3' }} | |
uses: docker/build-push-action@v4 | |
with: | |
push: true | |
file: backend/cmd/mintterd/Dockerfile | |
tags: mintter/mintterd:stable | |
- name: Build and push latest nextjs | |
uses: docker/build-push-action@v4 | |
with: | |
push: true | |
file: frontend/apps/site/Dockerfile | |
tags: mintter/sitegw:latest | |
- name: Build and push stable nextjs | |
if: ${{ steps.weekday.outputs.weekday == '3' }} | |
uses: docker/build-push-action@v4 | |
with: | |
push: true | |
file: frontend/apps/site/Dockerfile | |
tags: mintter/sitegw:stable | |
- name: Build and push latest monitord | |
uses: docker/build-push-action@v4 | |
with: | |
push: true | |
file: backend/cmd/monitord/Dockerfile | |
tags: mintter/monitord:latest | |
- name: Build and push stable monitord | |
if: ${{ steps.weekday.outputs.weekday == '3' }} | |
uses: docker/build-push-action@v4 | |
with: | |
push: true | |
file: backend/cmd/monitord/Dockerfile | |
tags: mintter/monitord:stable | |
- name: Build and push latest relay | |
uses: docker/build-push-action@v4 | |
with: | |
push: true | |
file: backend/cmd/relayd/Dockerfile | |
tags: mintter/relayd:latest | |
- name: Build and push stable relay | |
if: ${{ steps.weekday.outputs.weekday == '3' }} | |
uses: docker/build-push-action@v4 | |
with: | |
push: true | |
file: backend/cmd/relayd/Dockerfile | |
tags: mintter/relayd:stable |