Skip to content

publish as package

publish as package #7

Workflow file for this run

name: Docker image
on:
push:
workflow_dispatch:
repository_dispatch:
jobs:
docker-image:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: docker build -f Dockerfile -t btwiuse/portmux:${{ github.sha }} .
name: docker build
- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- run: docker push btwiuse/portmux:${{ github.sha }}
name: docker push
- run: |
docker tag btwiuse/portmux:${{ github.sha }} btwiuse/portmux
docker push btwiuse/portmux
if: github.ref == 'refs/heads/main'
name: docker push latest