Skip to content

Commit 8825550

Browse files
committed
2 parents 4f67842 + f265cae commit 8825550

File tree

2 files changed

+26
-2
lines changed

2 files changed

+26
-2
lines changed

.github/workflows/docker-image.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Docker Build and Push
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
if: github.repository == 'shuaiplus/nodecrypt'
11+
steps:
12+
- uses: actions/checkout@v4
13+
- name: Log in to GitHub Container Registry
14+
uses: docker/login-action@v3
15+
with:
16+
registry: ghcr.io
17+
username: ${{ github.actor }}
18+
password: ${{ secrets.GITHUB_TOKEN }}
19+
- name: Build and push Docker image
20+
uses: docker/build-push-action@v4
21+
with:
22+
context: .
23+
push: true
24+
tags: |
25+
ghcr.io/shuaiplus/nodecrypt:latest
26+
ghcr.io/shuaiplus/nodecrypt:${{ github.sha }}

README.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@
1818
### 方法三:Docker 一键部署(推荐自托管)
1919

2020
```bash
21-
docker run -d --name nodecrypt -p 80:80 shua1/nodecrypt
22-
or
2321
docker run -d --name nodecrypt -p 80:80 ghcr.io/shuaiplus/nodecrypt
2422
```
2523

0 commit comments

Comments
 (0)