Skip to content

Commit

Permalink
Update docker.yml
Browse files Browse the repository at this point in the history
return to standard action for docker
  • Loading branch information
sirbastiano authored Aug 2, 2023
1 parent ef495be commit 11037de
Showing 1 changed file with 16 additions and 20 deletions.
36 changes: 16 additions & 20 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,38 +7,34 @@
# To get a newer version, you will need to update the SHA.
# You can also reference a tag or branch, but the action may change without warning.

name: Build and publish a Docker image for PYRAWS
name: Build and Push Docker Image for PYRAWS

on:
push:
branches: [ "main" ]

workflow_dispatch:
branches: [ "main" ]

jobs:
push_to_registry:
name: Push Docker image to Docker Hub
build:
runs-on: ubuntu-latest
steps:
- name: Build the Docker image
-
name: Checkout
uses: actions/checkout@v3
- name: Log in to Docker Hub
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
-
name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
with:
images: ${{ secrets.DOCKER_USERNAME }}/pyraws

- name: Build and push Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
-
name: Build and push
uses: docker/build-push-action@v4
with:
context: .
file: ./Dockerfile
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
tags: ${{ secrets.DOCKER_USERNAME }}/pyraws:latest

0 comments on commit 11037de

Please sign in to comment.