diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml new file mode 100644 index 0000000..aa1d3de --- /dev/null +++ b/.github/workflows/docker-image.yml @@ -0,0 +1,37 @@ +name: docker-image + +on: + push: + branches: + - 'master' + paths-ignore: + - '**/README.md' + +jobs: + docker-image: + runs-on: ubuntu-latest + steps: + - + name: Checkout + uses: actions/checkout@v2 + - + name: Set up Docker Buildx + uses: docker/setup-buildx-action@v1 + - + name: Login to DockerHub + uses: docker/login-action@v1 + with: + username: ${{ secrets.DOCKER_HUB_USERNAME }} + password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} + - + name: Build and push + uses: docker/build-push-action@v2 + with: + context: . + file: docker/Dockerfile + push: true + tags: l4rm4nd/voucheme:latest + build-args: | + VERSION=${{ github.sha }} + BRANCH=${{ github.ref_name }} + platforms: linux/amd64