Skip to content

Latest commit

 

History

History
90 lines (68 loc) · 2.48 KB

File metadata and controls

90 lines (68 loc) · 2.48 KB

DevContainers

Docker Image Version Docker Image Size Docker Pulls Docker Stars

Docker Image packaging for DevContainers. (amd64, arm64)

Usage

To help you get started creating a container from this image you can either use docker-compose or the docker cli.

Docker Cli

Simple

docker run -d \
  --name=devcontainers \
  -e TZ=Asia/Shanghai \
  --restart unless-stopped \
  snowdreamtech/devcontainers:latest

Advance

docker run -d \
  --name=devcontainers \
  -e TZ=Asia/Shanghai \
  -v /path/to/data:/path/to/data \
  --restart unless-stopped \
  snowdreamtech/devcontainers:latest

Docker Compose

Simple

services:
  base:
    image: snowdreamtech/devcontainers:latest
    container_name: devcontainers
    environment:
      - TZ=Asia/Shanghai
    restart: unless-stopped

Advance

services:
  base:
    image: snowdreamtech/devcontainers:latest
    container_name: devcontainers
    environment:
      - TZ=Asia/Shanghai
    volumes:
      - /path/to/data:/path/to/data
    restart: unless-stopped

Development

docker buildx create --use --name build --node build --driver-opt network=host
docker buildx build -t snowdreamtech/devcontainers --platform=linux/amd64,linux/arm64 . --push

Reference

  1. 使用 buildx 构建多平台 Docker 镜像
  2. 如何使用 docker buildx 构建跨平台 Go 镜像
  3. Building Multi-Arch Images for Arm and x86 with Docker Desktop
  4. How to Rapidly Build Multi-Architecture Images with Buildx
  5. Faster Multi-Platform Builds: Dockerfile Cross-Compilation Guide
  6. docker/buildx

Contact (备注:devcontainers)

  • Email: sn0wdr1am@qq.com
  • QQ: 3217680847
  • QQ群: 949022145
  • WeChat/微信群: sn0wdr1am

License

MIT