Skip to content

Commit 4436045

Browse files
add compose file
1 parent 4fc12df commit 4436045

File tree

3 files changed

+27
-9
lines changed

3 files changed

+27
-9
lines changed

.github/workflows/docker.yml

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Build and check image
1+
name: Build
22
on:
33
push:
44
branches: ["master"]
@@ -44,16 +44,11 @@ jobs:
4444
4545
check:
4646
needs: [build]
47-
name: Pull image
47+
name: Check Trivy
4848
runs-on: [ubuntu-24.04]
4949
steps:
5050
- uses: actions/checkout@v4
51-
- name: Create report file
52-
run: |
53-
echo "BUILD TIME" > ${{ env.VER_LOG }}
54-
date +%s >> ${{ env.VER_LOG }}
55-
echo "---" >> ${{ env.VER_LOG }}
56-
- name: Check
51+
- name: Check Trivy
5752
run: |
5853
docker pull ${{ env.LATEST_TAG }}
5954
docker run --rm ghcr.io/rootshell-coder/trivy-cached:latest image ${{ env.LATEST_TAG }} --skip-db-update > ${{ env.TRIVY_SECURITY }}

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ docker compose
1010
---
1111
services:
1212
coco2:
13-
image: "person-detector"
13+
image: "ghcr.io/rootshell-coder/person-detector:latest"
1414
runtime: "nvidia-runc"
1515
ports:
1616
- "5000:5000"
@@ -30,6 +30,8 @@ networks:
3030
name: "pd-net"
3131
```
3232
33+
Remove runtime: `runtime: "nvidia-runc"` if you do not know what is it or not CUDA support in the system.
34+
3335
Check my wedding photo directory and select all where a person is present.
3436

3537
```bash

docker-compose.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
---
2+
services:
3+
coco2:
4+
image: "ghcr.io/rootshell-coder/person-detector:latest"
5+
runtime: "nvidia-runc"
6+
ports:
7+
- "5000:5000"
8+
networks:
9+
- "pd-net"
10+
restart: "always"
11+
deploy:
12+
resources:
13+
limits:
14+
cpus: "6.0"
15+
memory: "2G"
16+
reservations:
17+
cpus: "1.0"
18+
memory: "2G"
19+
networks:
20+
pd-net:
21+
name: "pd-net"

0 commit comments

Comments
 (0)