Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/actions/features_parse/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ outputs:
runs:
using: composite
steps:
- uses: gardenlinux/python-gardenlinux-lib/.github/actions/setup@0.8.2
- uses: gardenlinux/python-gardenlinux-lib/.github/actions/setup@0.8.3
- id: result
shell: bash
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/actions/flavors_parse/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ outputs:
runs:
using: composite
steps:
- uses: gardenlinux/python-gardenlinux-lib/.github/actions/setup@0.8.2
- uses: gardenlinux/python-gardenlinux-lib/.github/actions/setup@0.8.3
- id: matrix
shell: bash
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description: Installs the given GardenLinux Python library
inputs:
version:
description: GardenLinux Python library version
default: "0.8.2"
default: "0.8.3"
runs:
using: composite
steps:
Expand Down
9 changes: 8 additions & 1 deletion src/gardenlinux/s3/s3_artifacts.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,11 +169,18 @@ def upload_from_directory(
md5sum = file_digest(fp, "md5").hexdigest()
sha256sum = file_digest(fp, "sha256").hexdigest()

if artifact.name.startswith(cname):
suffix = artifact.name[len(cname) :]

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Curious choice, I would do artifacte.name.replace(cname, '') but I like the smiley :]

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Both solutions will work of course ;)

else:
raise RuntimeError(
f"Artifact name '{artifact.name}' does not start with cname '{cname}'"
)

artifact_metadata = {
"name": artifact.name,
"s3_bucket_name": self._bucket.name,
"s3_key": s3_key,
"suffix": "".join(artifact.suffixes),
"suffix": suffix,
"md5sum": md5sum,
"sha256sum": sha256sum,
}
Expand Down