Skip to content

Commit 7692c11

Browse files
committed
Bygg og push image til team tilbake sitt Google Artifact Registry
1 parent de2198f commit 7692c11

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

Diff for: .github/workflows/tilbake-build.yml

+44
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Build-Deploy-Preprod
2+
on:
3+
push:
4+
branches:
5+
- main
6+
workflow_dispatch:
7+
8+
concurrency:
9+
group: ${{ github.workflow }}-${{ github.ref_name }}
10+
cancel-in-progress: true
11+
12+
permissions:
13+
contents: "read"
14+
id-token: "write"
15+
jobs:
16+
build-dev:
17+
name: Build and push
18+
runs-on: ubuntu-latest
19+
steps:
20+
- uses: actions/checkout@v4
21+
with:
22+
persist-credentials: false
23+
24+
- uses: actions/setup-java@v4
25+
with:
26+
java-version: 21
27+
distribution: 'temurin'
28+
cache: 'maven'
29+
30+
- name: Bygg med maven
31+
env:
32+
GITHUB_USERNAME: x-access-token
33+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
34+
run: mvn -B --no-transfer-progress package --settings .m2/maven-settings.xml --file pom.xml
35+
36+
- name: Bygg og push docker image
37+
uses: nais/docker-build-push@v0
38+
id: docker-push
39+
with:
40+
team: tilbake
41+
tag: latest
42+
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
43+
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
44+
byosbom: target/classes/META-INF/sbom/application.cdx.json

0 commit comments

Comments
 (0)