Skip to content

Commit ca65dde

Browse files
nightly-dev build
1 parent f33c48c commit ca65dde

2 files changed

Lines changed: 71 additions & 57 deletions

File tree

.github/workflows/release-nightly-dev.yml

Lines changed: 5 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -8,65 +8,13 @@ on:
88
schedule:
99
# every day at 5:00 UTC
1010
# in this case inputs are all null/empty, hence the default values are used below
11-
- cron: "30 * * * *"
12-
11+
- cron: "45 * * * *"
1312
workflow_dispatch:
14-
inputs:
15-
branch-to-build:
16-
# do not use branch as name as it will be master in a scheduled run
17-
type: string
18-
description: 'Branch to checkout, build and publish'
19-
required: false
20-
default: 'dev'
21-
tag:
22-
type: string
23-
description: 'Tag to apply to the images'
24-
required: false
25-
default: 'nightly-dev'
26-
2713

2814
jobs:
29-
tag:
30-
runs-on: ubuntu-latest
31-
steps:
32-
- name: Checkout
33-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
34-
with:
35-
ref: ${{ github.event.inputs.branch-to-build || 'dev'}}
36-
37-
- name: Configure git
38-
run: |
39-
git config --global user.name "${{ env.GIT_USERNAME }}"
40-
git config --global user.email "${{ env.GIT_EMAIL }}"
41-
42-
- name: Create new tag ${{ github.event.inputs.tag || 'nightly-dev'}}
43-
run: |
44-
git tag -f -a ${{ github.event.inputs.tag || 'nightly-dev'}} -m "[bot] release ${{ github.event.inputs.tag || 'nightly-dev'}}"
45-
git push origin ${{ github.event.inputs.tag || 'nightly-dev'}} -f
46-
47-
publish-docker-containers:
48-
needs: tag
49-
strategy:
50-
matrix:
51-
platform: ['linux/amd64', 'linux/arm64']
52-
fail-fast: false
53-
uses: ./.github/workflows/release-x-manual-docker-containers.yml
54-
with:
55-
release_number: ${{ github.event.inputs.tag || 'nightly-dev'}}
56-
platform: ${{ matrix.platform }}
57-
secrets: inherit
58-
59-
publish-container-digests:
60-
needs: publish-docker-containers
61-
uses: ./.github/workflows/release-x-manual-merge-container-digests.yml
62-
with:
63-
release_number: ${{ github.event.inputs.tag || 'nightly-dev' }}
64-
secrets: inherit
65-
66-
release-helm-chart:
67-
needs: publish-container-digests
68-
uses: ./.github/workflows/release-x-manual-helm-chart.yml
15+
nightly-build-dev:
16+
uses: ./.github/workflows/release-x-nightly.yml
6917
with:
70-
release_number: ${{ github.event.inputs.tag || 'nightly-dev'}}
18+
branch-to-build: 'dev'
19+
tag: 'nightly-dev'
7120
secrets: inherit
72-
Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
name: "Release-Nightly: Core"
2+
3+
env:
4+
GIT_USERNAME: "DefectDojo release bot"
5+
GIT_EMAIL: "dojo-release-bot@users.noreply.github.com"
6+
7+
on:
8+
workflow_call:
9+
inputs:
10+
branch-to-build:
11+
# do not use branch as name as it will be master in a scheduled run
12+
type: string
13+
description: 'Branch to checkout, build and publish'
14+
required: false
15+
default: 'dev'
16+
tag:
17+
type: string
18+
description: 'Tag to apply to the images'
19+
required: false
20+
default: 'nightly-dev'
21+
22+
jobs:
23+
tag:
24+
runs-on: ubuntu-latest
25+
steps:
26+
- name: Checkout
27+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
28+
with:
29+
ref: ${{ github.event.inputs.branch-to-build }}
30+
31+
- name: Configure git
32+
run: |
33+
git config --global user.name "${{ env.GIT_USERNAME }}"
34+
git config --global user.email "${{ env.GIT_EMAIL }}"
35+
36+
- name: Create new tag ${{ github.event.inputs.tag }}
37+
run: |
38+
git tag -f -a ${{ github.event.inputs.tag }} -m "[bot] release ${{ github.event.inputs.tag }}"
39+
git push origin ${{ github.event.inputs.tag }} -f
40+
41+
publish-docker-containers:
42+
needs: tag
43+
strategy:
44+
matrix:
45+
platform: ['linux/amd64', 'linux/arm64']
46+
fail-fast: false
47+
uses: ./.github/workflows/release-x-manual-docker-containers.yml
48+
with:
49+
release_number: ${{ github.event.inputs.tag }}
50+
platform: ${{ matrix.platform }}
51+
secrets: inherit
52+
53+
publish-container-digests:
54+
needs: publish-docker-containers
55+
uses: ./.github/workflows/release-x-manual-merge-container-digests.yml
56+
with:
57+
release_number: ${{ github.event.inputs.tag }}
58+
secrets: inherit
59+
60+
release-helm-chart:
61+
needs: publish-container-digests
62+
uses: ./.github/workflows/release-x-manual-helm-chart.yml
63+
with:
64+
release_number: ${{ github.event.inputs.tag }}
65+
secrets: inherit
66+

0 commit comments

Comments
 (0)