Skip to content

Commit

Permalink
add siepic repo tags to image tag
Browse files Browse the repository at this point in the history
  • Loading branch information
jasminabrar committed Dec 15, 2023
1 parent f44698e commit e9d26e7
Showing 1 changed file with 27 additions and 4 deletions.
31 changes: 27 additions & 4 deletions .github/workflows/Docker_Image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,32 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4

- name: Get the current date
id: date
run: echo "::set-output name=date::$(date +%Y%m%d)"
# - name: Get the current date
# id: date
# run: echo "::set-output name=date::$(date +%Y%m%d)"

- name: install jq
run: |
sudo apt-get update -y
sudo apt-get install jq -y
- name: get latest version of siepic ebeam pdk and siepic tools
id: get-version
run: |
# Get the latest release version from the target repository
EBEAM_PDK=$(curl -s -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
"https://api.github.com/repos/SiEPIC/SiEPIC_EBeam_PDK/releases/latest" \
| jq -r .tag_name)
TOOLS=$(curl -s -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
"https://api.github.com/repos/SiEPIC/SiEPIC-Tools/releases/latest" \
| jq -r .tag_name)
echo "EBEAM_PDK=$EBEAM_PDK" >> $GITHUB_ENV
echo "TOOLS=$TOOLS" >> $GITHUB_ENV
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Log in to the container registry
uses: docker/login-action@65b78e6e13532edd9afa3aa52ac7964289d1a9c1
Expand Down Expand Up @@ -73,5 +96,5 @@ jobs:
with:
context: .
push: true
tags: "${{ steps.meta.outputs.tags }}.${{ steps.date.outputs.date }}.${{ github.run_number }}"
tags: "${{ steps.meta.outputs.tags }}.${{ steps.get-version.EBEAM_PDK }}.${{ steps.get-version.TOOLS }}"
labels: ${{ steps.meta.outputs.labels }}

0 comments on commit e9d26e7

Please sign in to comment.