Skip to content

Commit 71fe139

Browse files
committed
changed the username, password, and included docker build job
1 parent 287a471 commit 71fe139

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

.github/workflows/push-docker-image.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,14 @@ jobs:
3939
uses: docker/metadata-action@96383f45573cb7f253c731d3b3ab81c87ef81934 # v5.0.0
4040
with:
4141
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
42+
43+
# Build Docker Image
44+
- name: Build Docker Image
45+
run: |
46+
docker build -t awesome-fastapi:${{ github.sha }} .
47+
docker run -d -p 8080:8080 awesome-fastapi:${{ github.sha }}
4248
4349
# Push the Docker image to the registry
44-
# https://github.com/docker/build-push-action
4550
- name: Push Docker Image to GHCR
4651
run: |
4752
docker push ghcr.io/${{ github.repository_owner }}/${{ env.IMAGE_NAME }}:latest

0 commit comments

Comments
 (0)