Skip to content

Commit 18830f0

Browse files
authored
Fix tag extraction for upload-artifacts job (#266)
1 parent 65e6382 commit 18830f0

File tree

1 file changed

+6
-19
lines changed

1 file changed

+6
-19
lines changed

.github/workflows/upload-artifacts.yml

+6-19
Original file line numberDiff line numberDiff line change
@@ -14,25 +14,16 @@ jobs:
1414
steps:
1515
- uses: actions/checkout@v4
1616

17-
- name: get-latest-version
18-
uses: miniscruff/changie-action@v2
19-
with:
20-
version: latest
21-
args: latest
22-
- name: get-latest-no-v-version
23-
uses: miniscruff/changie-action@v2
24-
with:
25-
version: latest
26-
# Echoes the same version as previous step, but without "v" prefix.
27-
# Is used as a docker image tag in the release step.
28-
# E.g. "v0.5.31" -> "0.5.31"
29-
args: latest --remove-prefix
17+
- name: parse-version-from-chart
18+
run: |
19+
VERSION=$(cat ./deploy/ydb-operator/Chart.yaml | sed -n 's/^version: //p')
20+
echo "VERSION=$VERSION" >> $GITHUB_ENV
3021
3122
- name: create-tag
3223
uses: mathieudutour/github-tag-action@v6.2
3324
with:
34-
tag_prefix: ""
35-
custom_tag: ${{ steps.get-latest-version.outputs.output }}
25+
tag_prefix: "v"
26+
custom_tag: "$VERSION"
3627
github_token: ${{ github.token }}
3728

3829
- name: install-dependencies
@@ -67,10 +58,6 @@ jobs:
6758
yc config --profile private-docker-helm-public-docker set service-account-key sa-key.json
6859
env:
6960
SA_KEYS_FOR_PRIVATE_DOCKER_HELM_AND_PUBLIC_DOCKER: ${{ secrets.SA_KEYS_FOR_PRIVATE_DOCKER_HELM_AND_PUBLIC_DOCKER }}
70-
- name: parse-version-from-chart
71-
run: |
72-
VERSION=$(cat ./deploy/ydb-operator/Chart.yaml | sed -n 's/^version: //p')
73-
echo "VERSION=$VERSION" >> $GITHUB_ENV
7461
- name: login-to-registries
7562
run: |
7663
cat sa-key.json | docker login --username json_key --password-stdin cr.yandex

0 commit comments

Comments
 (0)