Skip to content

CICD-055 · Check container runtime availability ​

Encyclopedia · Gitea runner fundamentals · All snippets

Previous · CICD-054 · Next · CICD-056

1. Where it fits ​

  • Placement Bash run step following checkout, or equivalent lab terminal.
  • Prerequisites Gitea Actions enabled, authorized trusted runner registered and local repository checked out when needed.
  • Platforms gitea-actions.

2. Copy the snippet ​

bash
docker version --format '{{.Server.Version}}'
docker info --format '{{.OSType}}/{{.Architecture}}'

3. How it works ​

docker version and info query the connected daemon. They distinguish a CLI installation from a working executor with a reachable socket.

4. Verify the result ​

Run on the trusted host. Socket access indicates substantial privileges.

Validation syntax-validated (Bash parse). Status definitions.