Skip to content

Update README.md

Update README.md #114

Workflow file for this run

name: ghcr_image
on: [push]
jobs:
ghcr_image:
if: github.repository == 'miniwdl-ext/miniwdl-aws' # don't run from forks
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: docker login ghcr.io
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: docker_build
run: |
python3 setup.py --version # generate RELEASE-VERSION
REPO="ghcr.io/miniwdl-ext/miniwdl-aws"
TAG="$(git describe --tags --always --dirty)"
docker pull public.ecr.aws/amazonlinux/amazonlinux:2
docker build --no-cache -t "${REPO}:${TAG}" .
IMAGE_ID="$(docker inspect ${REPO}:${TAG} | jq -r .[0].Id)"
docker push "${REPO}:${TAG}"
REPO_DIGEST="$(docker inspect ${REPO}:${TAG} | jq -r '.[0].RepoDigests[0]')"
echo "REPO=${REPO}" >> $GITHUB_ENV
echo "TAG=${TAG}" >> $GITHUB_ENV
echo "IMAGE_ID=${IMAGE_ID}" >> $GITHUB_ENV
echo "REPO_DIGEST=${REPO_DIGEST}" >> $GITHUB_ENV
- name: display
run: |
>&2 echo "Id: ${IMAGE_ID}"
echo "::set-output name=Id::${REPO}:${IMAGE_ID}"
>&2 echo "Tag: ${REPO}:${TAG}"
echo "::set-output name=Tag::${REPO}:${TAG}"
>&2 echo "RepoDigest: ${REPO_DIGEST}"
echo "::set-output name=RepoDigest::${REPO_DIGEST}"
outputs:
Id: ${{steps.display.outputs.Id}}
Tag: ${{steps.display.outputs.Tag}}
RepoDigest: ${{steps.display.outputs.RepoDigest}}