BuildKit-Container mit custom /etc/hosts
This commit is contained in:
parent
66a77babfe
commit
6ff113007e
1 changed files with 18 additions and 3 deletions
|
|
@ -17,8 +17,23 @@ jobs:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Create BuildKit config with custom hosts
|
||||||
|
run: |
|
||||||
|
mkdir -p ~/.docker
|
||||||
|
cat > ~/.docker/buildkitd.toml <<EOF
|
||||||
|
[registry."git.avatic.de"]
|
||||||
|
http = false
|
||||||
|
|
||||||
|
[worker.oci]
|
||||||
|
max-parallelism = 4
|
||||||
|
EOF
|
||||||
|
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
|
with:
|
||||||
|
driver-opts: network=host
|
||||||
|
buildkitd-flags: --allow-insecure-entitlement network.host
|
||||||
|
config: ~/.docker/buildkitd.toml
|
||||||
|
|
||||||
- name: Login to Gitea Container Registry
|
- name: Login to Gitea Container Registry
|
||||||
run: |
|
run: |
|
||||||
|
|
@ -29,8 +44,8 @@ jobs:
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
push: true
|
push: true
|
||||||
|
network: host
|
||||||
|
allow: network.host
|
||||||
tags: |
|
tags: |
|
||||||
git.avatic.de/${{ gitea.repository_owner }}/lcc:${{ gitea.sha }}
|
git.avatic.de/${{ gitea.repository_owner }}/lcc:${{ gitea.sha }}
|
||||||
git.avatic.de/${{ gitea.repository_owner }}/lcc:latest
|
git.avatic.de/${{ gitea.repository_owner }}/lcc:latest
|
||||||
cache-from: type=registry,ref=git.avatic.de/${{ gitea.repository_owner }}/lcc:buildcache
|
|
||||||
cache-to: type=registry,ref=git.avatic.de/${{ gitea.repository_owner }}/lcc:buildcache,mode=max
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue