prometheus/.github/actions/save_artifacts/action.yml
Julien Pivotto 4d13976e47
Update actions to keep permissions (#11289)
Signed-off-by: Julien Pivotto <roidelapluie@o11y.eu>

Signed-off-by: Julien Pivotto <roidelapluie@o11y.eu>
2022-09-08 15:46:32 +02:00

18 lines
479 B
YAML

# Tar is used because the default actions do not preserve directory structure
# and file mode.
name: Save artifacts
inputs:
directory:
type: string
description: Path of the directory to save
runs:
using: composite
steps:
- run: |
tar cvf artifact.tar ${{ inputs.directory }}
mv artifact.tar artifact-$(sha1sum artifact.tar|awk '{ print $1 }').tar
shell: bash
- uses: actions/upload-artifact@v3
with:
path: artifact-*.tar