mirror of
https://github.com/Tecnativa/docker-socket-proxy
synced 2025-01-02 20:00:55 +00:00
Push to docker hub as well from ci
This commit is contained in:
parent
d2dad86abe
commit
856cb4912c
17
.github/workflows/test.yaml
vendored
17
.github/workflows/test.yaml
vendored
@ -47,7 +47,7 @@ jobs:
|
|||||||
key: venv ${{ env.CACHE }}
|
key: venv ${{ env.CACHE }}
|
||||||
- run: pip install poetry
|
- run: pip install poetry
|
||||||
- name: Patch $PATH
|
- name: Patch $PATH
|
||||||
run: echo "PATH=$HOME/.local/bin:$PATH" >> $GITHUB_ENV
|
run: echo "$HOME/.local/bin" >> $GITHUB_PATH
|
||||||
- run: poetry install
|
- run: poetry install
|
||||||
# Run tests
|
# Run tests
|
||||||
- run: poetry run pytest
|
- run: poetry run pytest
|
||||||
@ -55,9 +55,6 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: test
|
needs: test
|
||||||
env:
|
env:
|
||||||
DOCKER_REGISTRY_PASSWORD: ${{ secrets.BOT_TOKEN }}
|
|
||||||
DOCKER_REGISTRY_USERNAME: ${{ secrets.BOT_LOGIN }}
|
|
||||||
DOCKER_REGISTRY: ghcr.io
|
|
||||||
DOCKER_REPO: tecnativa/docker-socket-proxy
|
DOCKER_REPO: tecnativa/docker-socket-proxy
|
||||||
steps:
|
steps:
|
||||||
# Prepare
|
# Prepare
|
||||||
@ -66,12 +63,17 @@ jobs:
|
|||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v1
|
uses: docker/setup-buildx-action@v1
|
||||||
# Build and push
|
# Build and push
|
||||||
|
- name: Login to DockerHub
|
||||||
|
uses: docker/login-action@v1
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKERHUB_LOGIN }}
|
||||||
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||||
- name: Login to GitHub Container Registry
|
- name: Login to GitHub Container Registry
|
||||||
uses: docker/login-action@v1
|
uses: docker/login-action@v1
|
||||||
with:
|
with:
|
||||||
registry: ghcr.io
|
registry: ghcr.io
|
||||||
username: ${{ env.DOCKER_REGISTRY_USERNAME }}
|
username: ${{ secrets.BOT_LOGIN }}
|
||||||
password: ${{ env.DOCKER_REGISTRY_PASSWORD }}
|
password: ${{ secrets.BOT_TOKEN }}
|
||||||
- name: Build and push
|
- name: Build and push
|
||||||
uses: docker/build-push-action@v2
|
uses: docker/build-push-action@v2
|
||||||
with:
|
with:
|
||||||
@ -81,4 +83,5 @@ jobs:
|
|||||||
load: false
|
load: false
|
||||||
push: true
|
push: true
|
||||||
tags: |
|
tags: |
|
||||||
${{ env.DOCKER_REGISTRY }}/${{ env.DOCKER_REPO }}
|
ghcr.io/${{ env.DOCKER_REPO }}
|
||||||
|
${{ env.DOCKER_REPO }}
|
||||||
|
Loading…
Reference in New Issue
Block a user