测试 Login to GitHub Container Registry

This commit is contained in:
严浩
2024-10-09 10:08:41 +08:00
committed by GitHub
parent 5f9ee59ce5
commit 602d25faa7
2 changed files with 15 additions and 19 deletions

View File

@ -15,14 +15,26 @@ jobs:
run: |
set -x
which pnpm
docker-build-push-test:
runs-on: ubuntu-latest
steps:
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ vars.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- uses: yanhao98/composite-actions/docker-build-push@main
id: docker-build-push
with:
login_username: ${{ secrets.DOCKERHUB_USERNAME }}
login_password: ${{ secrets.DOCKERHUB_TOKEN }}
build_file: ./docker-build-push/Dockerfile
build_platforms: linux/amd64
build_push: false