Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable building of images outside of GitPod! #1038

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
FROM ecarrel/dazzle:upgrade_go_zipexec

ENV RETRIGGER=3

ENV BUILDKIT_VERSION=0.10.6
ENV BUILDKIT_FILENAME=buildkit-v${BUILDKIT_VERSION}.linux-amd64.tar.gz

USER root

RUN apk add curl bash

# Install dazzle, buildkit and pre-commit
RUN curl -sSL https://github.com/moby/buildkit/releases/download/v${BUILDKIT_VERSION}/${BUILDKIT_FILENAME} | tar -xvz -C /usr
RUN curl -sSL https://github.com/mvdan/sh/releases/download/v3.5.1/shfmt_v3.5.1_linux_amd64 -o /usr/bin/shfmt \
&& chmod +x /usr/bin/shfmt
# RUN install-packages shellcheck \
# && pip3 install pre-commit
RUN curl -sSL https://github.com/mikefarah/yq/releases/download/v4.22.1/yq_linux_amd64 -o /usr/bin/yq && chmod +x /usr/bin/yq

ADD . workspace-images/
WORKDIR workspace-images
33 changes: 33 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
services:
buildkitd:
image: docker.io/moby/buildkit:latest
command: ["--addr", "tcp://0.0.0.0:1234"]
networks:
- "dazzle-net"
ports:
- "1234:1234"

registry:
image: registry:2
networks:
- "dazzle-net"
expose:
- "5000"
ports:
- "5000:5000"

workspace-images:
image: workspace-images
depends_on:
- buildkitd
- registry
environment:
DAZZLE_BUILDKITD_ADDR=tcp://buildkitd:5000
networks:
- "dazzle-net"
profiles:
- cmd


networks:
dazzle-net: {}