CI: install Docker from static binary, keep all paths under /tmp
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
077cc53d27
commit
a99e367a49
1 changed files with 16 additions and 4 deletions
|
|
@ -14,11 +14,23 @@ jobs:
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Install and start Docker
|
- name: Install Docker from static binary
|
||||||
run: |
|
run: |
|
||||||
apt-get update -qq && apt-get install -y --no-install-recommends docker.io
|
curl -fsSL https://download.docker.com/linux/static/stable/x86_64/docker-27.5.1.tgz \
|
||||||
nohup dockerd &>/var/log/dockerd.log &
|
| tar -xz -C /tmp
|
||||||
until docker info >/dev/null 2>&1; do sleep 1; done
|
echo "/tmp/docker" >> "$GITHUB_PATH"
|
||||||
|
|
||||||
|
- name: Start Docker daemon
|
||||||
|
run: |
|
||||||
|
mkdir -p /tmp/docker-data /tmp/docker-run
|
||||||
|
nohup /tmp/docker/dockerd \
|
||||||
|
--host=unix:///tmp/docker-run/docker.sock \
|
||||||
|
--data-root=/tmp/docker-data \
|
||||||
|
&>/tmp/dockerd.log &
|
||||||
|
echo "DOCKER_HOST=unix:///tmp/docker-run/docker.sock" >> "$GITHUB_ENV"
|
||||||
|
until /tmp/docker/docker --host=unix:///tmp/docker-run/docker.sock info >/dev/null 2>&1; do
|
||||||
|
sleep 1
|
||||||
|
done
|
||||||
|
|
||||||
- name: Log in to registry
|
- name: Log in to registry
|
||||||
run: |
|
run: |
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue