-
Notifications
You must be signed in to change notification settings - Fork 0
68 lines (62 loc) · 1.75 KB
/
docker-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
name: docker-ci
on:
# enable manual trigger
workflow_dispatch:
schedule:
# every 24 hours at midnight
- cron: '0 0 * * *'
push:
branches:
- main
paths:
- '.github/workflows/docker-ci.yml'
- 'docker/**'
tags:
- 'v[0-9]+.[0-9]+.[0-9]+'
env:
DOCKER_REPOSITORY: hckops
jobs:
docker:
name: Docker
runs-on: ubuntu-latest
timeout-minutes: 30
# parallel jobs
strategy:
matrix:
images:
- path: .
name: alpine-openvpn
nightly: true
- path: .
name: alpine-tty
nightly: true
- path: .
name: arch-tty
nightly: true
- path: .
name: metasploit
nightly: true
- path: .
name: parrot-core
nightly: true
- path: .
name: ubuntu-tty
nightly: true
# exclude from nightly schedule
- path: ctf
name: htb-postman
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Docker CI
if: ${{ github.event_name != 'schedule' || (github.event_name == 'schedule' && matrix.images.nightly) }}
uses: hckops/actions/docker-template-action@v0.10.8
with:
DOCKER_CONTEXT: ./docker/${{ matrix.images.path }}/${{ matrix.images.name }}
DOCKER_IMAGE_NAME: ${{ matrix.images.name }}
DOCKER_REPOSITORY: ${{ env.DOCKER_REPOSITORY }}
DOCKER_DEFAULT_TAG: 'latest'
# repository secrets
SECRET_DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
SECRET_DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
SECRET_DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_URL }}