Skip to content

Commit af56ba5

Browse files
committed
fix env variable
1 parent 14b79fc commit af56ba5

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

.github/workflows/publish-to-dafni.yaml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,7 @@ jobs:
3232
DAFNI_PARENT_ID: ${{ secrets.DAFNI_PARENT_ID }}
3333
DAFNI_USERNAME: ${{ secrets.DAFNI_USERNAME }}
3434
DAFNI_PASSWORD: ${{ secrets.DAFNI_PASSWORD }}
35-
CTF_VERSION: |
36-
version=${{ github.event.release.tag_name }}
37-
version=${version%%.*}
35+
CTF_VERSION: ${{ github.event.release.tag_name[1:2] }}
3836

3937
steps:
4038
- uses: actions/checkout@v3
@@ -43,8 +41,8 @@ jobs:
4341
python-version: 3.9
4442
- name: Build the container
4543
run: |
46-
docker build -t ctf:${version} -f ./dafni/Dockerfile .
47-
docker save ctf:${version} | gzip > ctf${version}.tar.gz
44+
docker build -t ctf:${CTF_VERSION} -f ./dafni/Dockerfile .
45+
docker save ctf:${CTF_VERSION} | gzip > ctf${CTF_VERSION}.tar.gz
4846
4947
- name: Install DAFNI-CLI and log in
5048
run: |
@@ -53,5 +51,5 @@ jobs:
5351
5452
- name: Upload to DAFNI
5553
run: |
56-
dafni upload model ./dafni/model_definition.yaml ctf${version}.tar.gz --version-message "Version ${version}. Uploaded via Github." --parent-id ${DAFNI_PARENT_ID} -y
54+
dafni upload model ./dafni/model_definition.yaml ctf${CTF_VERSION}.tar.gz --version-message "Version ${CTF_VERSION}. Uploaded via Github." --parent-id ${DAFNI_PARENT_ID} -y
5755
dafni logout

0 commit comments

Comments
 (0)