File tree Expand file tree Collapse file tree 2 files changed +55
-0
lines changed Expand file tree Collapse file tree 2 files changed +55
-0
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ name : Build Container Image CI
3
+
4
+ on :
5
+ workflow_dispatch :
6
+ push :
7
+ branches : [ master ]
8
+ tags : [ '*' ]
9
+ pull_request :
10
+ branches : [ master ]
11
+
12
+ env :
13
+ REGISTRY : ghcr.io
14
+ IMAGE_NAME : ${{ github.repository }}
15
+
16
+ jobs :
17
+ build :
18
+ runs-on : ubuntu-latest
19
+
20
+ steps :
21
+ - name : Checkout repository
22
+ uses : actions/checkout@v4
23
+ with :
24
+ repository : ccrisan/motioneye
25
+
26
+ - name : Setup Docker buildx
27
+ uses : docker/setup-buildx-action@v2
28
+
29
+ - name : Login with Github Container registry
30
+ if : github.event_name != 'pull_request'
31
+ uses : docker/login-action@v2
32
+ with :
33
+ registry : ${{ env.REGISTRY }}
34
+ username : ${{ github.actor }}
35
+ password : ${{ secrets.GITHUB_TOKEN }}
36
+
37
+ - name : Extract Docker metadata
38
+ id : meta
39
+ uses : docker/metadata-action@v4
40
+ with :
41
+ images : ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
42
+
43
+ - name : Build and push Docker image
44
+ id : build-and-push
45
+ uses : docker/build-push-action@v6
46
+ with :
47
+ context : .
48
+ file : docker/Dockerfile
49
+ push : ${{ github.event_name != 'pull_request' }}
50
+ tags : ${{ steps.meta.outputs.tags }}
51
+ labels : ${{ steps.meta.outputs.labels }}
52
+ cache-from : type=gha
53
+ cache-to : type=gha,mode=max
Original file line number Diff line number Diff line change
1
+ ## docker-motioneye
2
+ CI to build the latest version of Motioneye from Git and publish to ghcr.
You can’t perform that action at this time.
0 commit comments