File tree Expand file tree Collapse file tree 3 files changed +49
-4
lines changed
Expand file tree Collapse file tree 3 files changed +49
-4
lines changed Original file line number Diff line number Diff line change 2626 username : ${{ github.actor }}
2727 password : ${{ secrets.GITHUB_TOKEN }}
2828
29- - name : Build the Docker image
30- run : |
31- docker build . --tag ghcr.io/ntxinh/aspnetcore-ddd:latest
32- docker push ghcr.io/ntxinh/aspnetcore-ddd:latest
29+ # Method 1
30+ # -
31+ # name: Docker Build and Push
32+ # continue-on-error: true
33+ # run: |
34+ # docker build . --tag ghcr.io/ntxinh/aspnetcore-ddd:latest
35+ # docker push ghcr.io/ntxinh/aspnetcore-ddd:latest
36+
37+ # Method 2
38+ -
39+ name : Docker Build and Push by Action
40+ # continue-on-error: true
41+ uses : docker/build-push-action@v5
42+ with :
43+ push : true
44+ tags : ghcr.io/ntxinh/aspnetcore-ddd:latest
45+
46+ # Method 3:
47+ # -
48+ # name: Docker Build and Push by Docker Compose
49+ # continue-on-error: true
50+ # run: |
51+ # docker compose build
52+ # docker compose push
Original file line number Diff line number Diff line change @@ -85,6 +85,14 @@ docker run -d -p 3000:80 --name aspnetcore-docker-container aspnetcore-docker-im
8585
8686- http://localhost:3000/
8787
88+ ``` bash
89+ docker compose up -d
90+ docker compose ps
91+ docker compose stop
92+ ```
93+
94+ - http://localhost:80/
95+
8896# Podman
8997
9098``` bash
@@ -95,6 +103,14 @@ podman run -d -p 3000:80 --name aspnetcore-docker-container aspnetcore-docker-im
95103
96104- http://localhost:3000/
97105
106+ ``` bash
107+ podman-compose up -d
108+ podman-compose ps
109+ podman-compose stop
110+ ```
111+
112+ - http://localhost:80/
113+
98114# Swagger (Dev env only)
99115- http://localhost:5000/swagger
100116
Original file line number Diff line number Diff line change 1+ services :
2+ web :
3+ image : ghcr.io/ntxinh/aspnetcore-ddd:latest
4+ build : .
5+ ports :
6+ - " 80:80"
7+ - " 443:443"
8+ # environment:
9+ # ASPNETCORE_ENVIRONMENT: ${MyEnv}
You can’t perform that action at this time.
0 commit comments