Skip to content

Commit af6a71f

Browse files
committed
Korjaa buildversion.txt generointi CI:ssä
1 parent 8157ef6 commit af6a71f

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

.github/actions/build_koski/action.yaml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,11 @@ runs:
4848
${{ runner.os }}-node-
4949
- name: Build Koski app + tests
5050
if: steps.lookup.outputs.cache-hit != 'true'
51-
run: mvn test -DskipTests=true --batch-mode
51+
env:
52+
version: ${{ inputs.commithash }}
53+
run: |
54+
mvn versions:set -DnewVersion="$version" --batch-mode
55+
mvn test -DskipTests=true --batch-mode
5256
shell: bash
5357
- name: Cache target dir
5458
if: steps.lookup.outputs.cache-hit != 'true'

.github/workflows/publish_image.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ jobs:
8686
version: ${{ inputs.commithash }}
8787
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
8888
run: |
89-
mvn versions:set -DnewVersion="$version"
89+
mvn versions:set -DnewVersion="$version" --batch-mode
9090
mvn war:war deploy:deploy --batch-mode -Dmaven.skip.install=true -DaltDeploymentRepository=github::default::https://maven.pkg.github.com/Opetushallitus/koski
9191
9292
- name: Build, tag, and push image to Amazon ECR

0 commit comments

Comments
 (0)