Skip to content

Commit a8d6043

Browse files
committed
updated workflow
1 parent afbf4ca commit a8d6043

File tree

3 files changed

+3
-62
lines changed

3 files changed

+3
-62
lines changed

.github/workflows/release_beta.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,4 +63,4 @@ jobs:
6363
make_latest: true # change this to false when stable gets released
6464
draft: false
6565
generate_release_notes: true
66-
name: ${{ steps.extract_branch.outputs.tag_name }}
66+
name: ${{ steps.extract_branch.outputs.tag_name }}

.github/workflows/release_dev.yaml

Lines changed: 1 addition & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -59,26 +59,4 @@ jobs:
5959
file: ./_docker/Dockerfile
6060
push: true
6161
tags: ${{ steps.modify-json.outputs.cleaned_tag }}
62-
labels: ${{ steps.meta.outputs.labels }}
63-
- name: Modify version names
64-
id: modify-json-media
65-
run: |
66-
TAGS="${{ steps.meta.outputs.tags }}"
67-
# Apply modifications to both docker.io and ghcr.io tags
68-
CLEANED_TAGS=$(echo "$TAGS" | sed 's/filebrowser:dev-v/filebrowser:/g' | sed -E 's/(filebrowser:[0-9]+\.[0-9]+\.[0-9]+)/\1-dev-media/g')
69-
# Add dev tag to both registries
70-
CLEANED_TAGS="$CLEANED_TAGS,gtstef/filebrowser:dev-media,ghcr.io/gtsteffaniak/filebrowser:dev-media"
71-
echo "cleaned_tag<<EOF" >> $GITHUB_OUTPUT
72-
echo "$CLEANED_TAGS" >> $GITHUB_OUTPUT
73-
echo "EOF" >> $GITHUB_OUTPUT
74-
- name: Build and push media image
75-
uses: docker/build-push-action@v6
76-
with:
77-
context: .
78-
build-args: |
79-
VERSION=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.version'] }}
80-
REVISION=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.revision'] }}
81-
file: ./_docker/Dockerfile.media
82-
push: true
83-
tags: ${{ steps.modify-json-media.outputs.cleaned_tag }}
84-
labels: ${{ steps.meta.outputs.labels }}
62+
labels: ${{ steps.meta.outputs.labels }}

.github/workflows/tag.yaml

Lines changed: 1 addition & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -95,41 +95,4 @@ jobs:
9595
file: ./_docker/Dockerfile
9696
push: true
9797
tags: ${{ steps.modify-json.outputs.cleaned_tag }}
98-
labels: ${{ steps.meta.outputs.labels }}
99-
- name: Modify version names
100-
id: modify-json-media
101-
run: |
102-
JSON='${{ steps.meta.outputs.json }}'
103-
MODIFIED_JSON=$(echo "$JSON" | jq '
104-
.tags |= map(sub(":v"; ":")) |
105-
if any(.tags[]; test("beta")) then
106-
.tags += [
107-
"gtstef/filebrowser:beta-media",
108-
"ghcr.io/gtsteffaniak/filebrowser:beta-media",
109-
"gtstef/filebrowser:media",
110-
"ghcr.io/gtsteffaniak/filebrowser:media"
111-
]
112-
else . end |
113-
if any(.tags[]; test("stable")) then
114-
.tags += [
115-
"gtstef/filebrowser:stable-media",
116-
"ghcr.io/gtsteffaniak/filebrowser:stable-media",
117-
"gtstef/filebrowser:media",
118-
"ghcr.io/gtsteffaniak/filebrowser:media"
119-
]
120-
else . end
121-
')
122-
TAGS_CSV=$(echo "$MODIFIED_JSON" | jq -r '.tags | join(",")')
123-
echo "$TAGS_CSV" > modified_tags.txt # Optional debug output
124-
echo "cleaned_tag=$TAGS_CSV" >> $GITHUB_OUTPUT
125-
- name: Build and push media image
126-
uses: docker/build-push-action@v6
127-
with:
128-
context: .
129-
build-args: |
130-
VERSION=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.version'] }}
131-
REVISION=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.revision'] }}
132-
file: ./_docker/Dockerfile.media
133-
push: true
134-
tags: ${{ steps.modify-json-media.outputs.cleaned_tag }}
135-
labels: ${{ steps.meta.outputs.labels }}
98+
labels: ${{ steps.meta.outputs.labels }}

0 commit comments

Comments
 (0)