Skip to content

Commit 8838fe1

Browse files
authored
Migrate to GitHub Actions (#35)
<!-- markdownlint-disable MD041 --> #### What this PR does / why we need it #### Which issue(s) this PR fixes <!-- Usage: `Fixes #<issue number>`, or `Fixes (paste link of issue)`. -->
1 parent 5f01fe6 commit 8838fe1

File tree

5 files changed

+116
-40
lines changed

5 files changed

+116
-40
lines changed

.ci/pipeline_definitions

Lines changed: 0 additions & 40 deletions
This file was deleted.

.github/workflows/build.yaml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
name: Build
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
mode:
7+
required: true
8+
type: string
9+
default: snapshot
10+
description: |
11+
the mode to use. either `snapshot` or `release`. Will affect effective version, as well
12+
as target-oci-registry.
13+
14+
jobs:
15+
prepare:
16+
uses: gardener/cc-utils/.github/workflows/prepare.yaml@master
17+
permissions:
18+
contents: read
19+
with:
20+
mode: ${{ inputs.mode }}
21+
22+
oci-images:
23+
name: Build OCI-Images
24+
uses: gardener/cc-utils/.github/workflows/oci-ocm.yaml@master
25+
needs:
26+
- prepare
27+
permissions:
28+
contents: read
29+
packages: write
30+
id-token: write
31+
with:
32+
name: signing-server
33+
version: ${{ needs.prepare.outputs.version }}
34+
oci-registry: ${{ needs.prepare.outputs.oci-registry }}
35+
oci-repository: cicd/signing-server
36+
oci-platforms: linux/amd64
37+
ctx: oci-images
38+
39+
helmcharts:
40+
name: Build Helmcharts
41+
uses: gardener/cc-utils/.github/workflows/helmchart-ocm.yaml@master
42+
needs:
43+
- prepare
44+
- oci-images
45+
permissions:
46+
contents: read
47+
packages: write
48+
id-token: write
49+
with:
50+
name: signing-server
51+
dir: chart
52+
oci-registry: ${{ needs.prepare.outputs.oci-registry }}
53+
oci-repository: cicd/charts
54+
ocm-mappings: |
55+
- ref: ocm-resource:signing-server.repository
56+
attribute: image.repository
57+
- ref: ocm-resource:signing-server.tag
58+
attribute: image.tag

.github/workflows/non-release.yaml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: CI (non-release)
2+
on:
3+
push:
4+
workflow_dispatch:
5+
6+
jobs:
7+
build:
8+
uses: ./.github/workflows/build.yaml
9+
secrets: inherit
10+
permissions:
11+
contents: read
12+
packages: write
13+
id-token: write
14+
with:
15+
mode: snapshot
16+
17+
component-descriptor:
18+
uses: gardener/cc-utils/.github/workflows/post-build.yaml@master
19+
needs:
20+
- build
21+
secrets: inherit
22+
permissions:
23+
contents: write
24+
id-token: write

.github/workflows/release.yaml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Release
2+
on:
3+
workflow_dispatch:
4+
inputs:
5+
next-version:
6+
type: choice
7+
options:
8+
- bump-minor
9+
- bump-patch
10+
11+
jobs:
12+
build:
13+
uses: ./.github/workflows/build.yaml
14+
secrets: inherit
15+
permissions:
16+
contents: read
17+
packages: write
18+
id-token: write
19+
with:
20+
mode: release
21+
22+
release-to-github-and-bump:
23+
uses: gardener/cc-utils/.github/workflows/release.yaml@master
24+
needs:
25+
- build
26+
secrets: inherit
27+
permissions:
28+
contents: write
29+
packages: write
30+
id-token: write
31+
with:
32+
release-commit-target: branch
33+
next-version: ${{ inputs.next-version }}

.ocm/base-component.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
name: ocm.software/signing-server

0 commit comments

Comments
 (0)