Skip to content

Commit

Permalink
faak
Browse files Browse the repository at this point in the history
  • Loading branch information
espenhgn committed Apr 30, 2024
1 parent 5b50ba3 commit 590dd3c
Showing 1 changed file with 13 additions and 8 deletions.
21 changes: 13 additions & 8 deletions .github/workflows/docker_build_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,17 @@ jobs:
- name: Pull and push Singularity container
run: |
tags="${{ steps.meta.outputs.tags }}"
IFS=$'\n' read -r -d '' -a tags_array <<< "$tags"
echo "$tags"
echo ${{ secrets.GITHUB_TOKEN }} | oras login --username ${{ github.repository_owner }} --password-stdin ghcr.io
for tag in "${tags_array[@]}"; do
echo "processing: " "$tag"
singularity pull nothingtoseehere.sif docker://"$tag"
oras push ghcr.io/"$tag" --artifact-type application/vnd.acme.rocket.config nothingtoseehere.sif
done
if [ -n "$tags" ]; then
IFS=$'\n' read -r -d '' -a tags_array <<< "$tags"
echo "Number of tags: ${#tag_array[@]}"
echo "$tags"
echo ${{ secrets.GITHUB_TOKEN }} | oras login --username ${{ github.repository_owner }} --password-stdin ghcr.io
for tag in "${tags_array[@]}"; do
echo "processing tag: $tag"
singularity pull nothingtoseehere.sif docker://"$tag"
oras push ghcr.io/"$tag" --artifact-type application/vnd.acme.rocket.config nothingtoseehere.sif
done
else
echo "No tags found"
fi
shell: bash

0 comments on commit 590dd3c

Please sign in to comment.