mirror of
https://github.com/searxng/searxng.git
synced 2025-08-02 18:12:21 +02:00
[fix] DOCKERHUB_USERNAME env reference (#4778)
Some checks are pending
Documentation / Release (push) Waiting to run
Integration / Python 3.10 (push) Waiting to run
Integration / Python 3.11 (push) Waiting to run
Integration / Python 3.12 (push) Waiting to run
Integration / Python 3.13 (push) Waiting to run
Integration / Python 3.9 (push) Waiting to run
Integration / Theme (push) Waiting to run
Some checks are pending
Documentation / Release (push) Waiting to run
Integration / Python 3.10 (push) Waiting to run
Integration / Python 3.11 (push) Waiting to run
Integration / Python 3.12 (push) Waiting to run
Integration / Python 3.13 (push) Waiting to run
Integration / Python 3.9 (push) Waiting to run
Integration / Theme (push) Waiting to run
When making the container rework, I unknowingly deleted the section where an env with the same name as the secret was defined on the job scope, making it look like it was originally defined as an organization env. Since we can't validate the secrets in a condition directly, it's better to let docker/login-action take care of failing the entire job if the credentials are invalid. Reported in: https://github.com/searxng/searxng/issues/4777
This commit is contained in:
parent
945b30a1c4
commit
5d99373bc6
1 changed files with 5 additions and 9 deletions
14
.github/workflows/container.yml
vendored
14
.github/workflows/container.yml
vendored
|
@ -153,30 +153,26 @@ jobs:
|
|||
- test
|
||||
|
||||
steps:
|
||||
- if: env.DOCKERHUB_USERNAME != null
|
||||
name: Checkout
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
persist-credentials: "false"
|
||||
|
||||
- if: env.DOCKERHUB_USERNAME != null
|
||||
name: Login to GHCR
|
||||
- name: Login to GHCR
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: "ghcr.io"
|
||||
username: "${{ github.repository_owner }}"
|
||||
password: "${{ secrets.GITHUB_TOKEN }}"
|
||||
|
||||
- if: env.DOCKERHUB_USERNAME != null
|
||||
name: Login to Docker Hub
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: "docker.io"
|
||||
username: "${{ env.DOCKERHUB_USERNAME }}"
|
||||
username: "${{ secrets.DOCKERHUB_USERNAME }}"
|
||||
password: "${{ secrets.DOCKERHUB_TOKEN }}"
|
||||
|
||||
- if: env.DOCKERHUB_USERNAME != null
|
||||
name: Release
|
||||
- name: Release
|
||||
env:
|
||||
GIT_URL: "${{ needs.build.outputs.git_url }}"
|
||||
DOCKER_TAG: "${{ needs.build.outputs.docker_tag }}"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue