Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use the Docker login action #8

Merged
merged 1 commit into from
Feb 1, 2024
Merged
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
9 changes: 7 additions & 2 deletions .github/workflows/docs-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,16 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 2
- name: Log in to Container Registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Detect change
id: change
run: |
export COMMIT_SHORT_SHA="${GITHUB_SHA:0:8}"
echo "${{ secrets.GITHUB_TOKEN }}" | docker login -u "${{ github.actor }}" --password-stdin "${{env.REGISTRY}}"
if ! docker manifest inspect "${REGISTRY}/${IMAGE_NAME}:${TAG}" 2>&1 > /dev/null ; then export NEEDS_IMAGE=true ; fi
def_branch=$(gh api "repos/${GITHUB_REPOSITORY}" -q '.default_branch')
git fetch origin "${def_branch}"
Expand Down Expand Up @@ -70,7 +75,7 @@ jobs:
with:
fetch-depth: 1
- name: Log in to Container Registry
uses: docker/login-action@v2
uses: docker/login-action@v3
Copy link
Member

Choose a reason for hiding this comment

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

It's not critical, but we may want to configure dependabot on this repo to automate updates such as these.

with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
Expand Down
Loading