Skip to content
This repository has been archived by the owner on Aug 22, 2022. It is now read-only.

Commit

Permalink
Add more information in the README
Browse files Browse the repository at this point in the history
* Add `shields.io` badges
* Add information about the build architectures
* Add information about added packages
* Update the example
  • Loading branch information
tlex committed Sep 13, 2020
1 parent bfb1b82 commit eba74a8
Showing 1 changed file with 22 additions and 11 deletions.
33 changes: 22 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,22 @@
[![Pipeline Status](https://gitlab.com/ix.ai/docker-buildx-qemu/badges/master/pipeline.svg)](https://gitlab.com/ix.ai/docker-buildx-qemu/)
[![Docker Stars](https://img.shields.io/docker/stars/ixdotai/docker-buildx-qemu.svg)](https://hub.docker.com/r/ixdotai/docker-buildx-qemu/)
[![Docker Pulls](https://img.shields.io/docker/pulls/ixdotai/docker-buildx-qemu.svg)](https://hub.docker.com/r/ixdotai/docker-buildx-qemu/)
[![Docker Image Version (latest)](https://img.shields.io/docker/v/ixdotai/docker-buildx-qemu/latest)](https://hub.docker.com/r/ixdotai/docker-buildx-qemu/)
[![Docker Image Size (latest)](https://img.shields.io/docker/image-size/ixdotai/docker-buildx-qemu/latest)](https://hub.docker.com/r/ixdotai/docker-buildx-qemu/)
[![Gitlab Project](https://img.shields.io/badge/GitLab-Project-554488.svg)](https://gitlab.com/ix.ai/docker-buildx-qemu/)

This Debian-based image allows you to easily build cross-platform images.
This Debian-slim-based image allows you to easily build cross-platform images.
It's been tested with GitLab CI on gitlab.com, but it should work anywhere that docker-in-docker already works, and with a `binfmt_misc` enabled kernel.

The `ixdotai/docker-buildx-qemu` image supports the following architectures:
* `amd64`
* `arm64`

The following additional tools are installed, to be used in your pipelines:
* `curl`
* `git`
* `jq`

## Example Usage

This GitLab example should give you an idea of how to use the image.
Expand All @@ -22,27 +33,27 @@ RUN echo "Hello, my CPU architecture is $(uname -m)"
.gitlab-ci.yml
```yaml
variables:
DOCKER_TLS_CERTDIR: "/certs"
DOCKER_CERT_PATH: "/certs/client"
DOCKER_TLS: 'true'
DOCKER_HOST: tcp://docker:2376/
BUILDKIT_INLINE_CACHE: '1'
DOCKER_DRIVER: overlay2
CI_BUILD_ARCHS: "linux/arm/v7,linux/arm64,linux/amd64"
CI_BUILD_IMAGE: "ixdotai/docker-buildx-qemu:latest"

build:
image: $CI_BUILD_IMAGE
stage: build
services:
- name: docker:dind
entrypoint: ["env", "-u", "DOCKER_HOST"]
command: ["dockerd-entrypoint.sh"]
variables:
DOCKER_HOST: tcp://docker:2375/
DOCKER_DRIVER: overlay2
# See https://github.com/docker-library/docker/pull/166
DOCKER_TLS_CERTDIR: ""
- docker:dind
retry: 2
before_script:
- echo "$CI_REGISTRY_PASSWORD" | docker login -u "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY
# Use docker-container driver to allow useful features (push/multi-platform)
- update-binfmts --enable # Important: Ensures execution of other binary formats is enabled in the kernel
- docker buildx create --driver docker-container --use
# Use docker-container driver to allow useful features (push/multi-platform)
- docker context create MyContext
- docker buildx create --driver docker-container --name MyContext --use MyContext
- docker buildx inspect --bootstrap
script:
- docker buildx ls
Expand Down

0 comments on commit eba74a8

Please sign in to comment.