|
| 1 | +# renovate: datasource=docker depName=ghcr.io/containerbase/base |
| 2 | +ARG CONTAINERBASE_VERSION=9.26.0 |
| 3 | + |
| 4 | +FROM ghcr.io/containerbase/base:${CONTAINERBASE_VERSION} as containerbase |
| 5 | + |
| 6 | +FROM amd64/ubuntu:jammy as base |
| 7 | + |
| 8 | +ARG CONTAINERBASE_VERSION |
| 9 | +ARG APT_HTTP_PROXY |
| 10 | + |
| 11 | +LABEL org.opencontainers.image.source="https://github.com/containerbase/gitpod" \ |
| 12 | + org.opencontainers.image.version="${CONTAINERBASE_VERSION}" |
| 13 | + |
| 14 | +# Compatibillity |
| 15 | +LABEL org.label-schema.vcs-url="https://github.com/containerbase/gitpod" \ |
| 16 | + org.label-schema.version="${CONTAINERBASE_VERSION}" |
| 17 | + |
| 18 | +ARG USER_NAME=gitpod |
| 19 | +ARG USER_ID=33333 |
| 20 | +ARG PRIMARY_GROUP_ID=33333 |
| 21 | + |
| 22 | +# Set env and shell |
| 23 | +ENV BASH_ENV=/usr/local/etc/env ENV=/usr/local/etc/env PATH=/home/$USER_NAME/bin:$PATH |
| 24 | +SHELL ["/bin/bash" , "-c"] |
| 25 | + |
| 26 | +# This entry point ensures that dumb-init is run |
| 27 | +ENTRYPOINT [ "docker-entrypoint.sh" ] |
| 28 | + |
| 29 | +# Set up containerbase |
| 30 | +COPY --from=containerbase /usr/local/bin/ /usr/local/bin/ |
| 31 | +COPY --from=containerbase /usr/local/containerbase/ /usr/local/containerbase/ |
| 32 | +RUN install-containerbase |
| 33 | + |
| 34 | +# add required gitpod packages |
| 35 | +RUN set -ex; \ |
| 36 | + install-apt make shellcheck sudo locales; \ |
| 37 | + locale-gen en_US.UTF-8; \ |
| 38 | + true |
| 39 | + |
| 40 | +# allow sudo without password |
| 41 | +RUN echo "gitpod ALL=NOPASSWD:ALL" > /etc/sudoers.d/gitpod; sudo id |
| 42 | + |
| 43 | +# renovate: datasource=github-tags packageName=git/git |
| 44 | +RUN install-tool git v2.30.0 |
| 45 | + |
| 46 | +# mark all directories as safe |
| 47 | +RUN git config --system --add safe.directory '*' |
| 48 | + |
| 49 | +# renovate: datasource=github-releases depName=docker lookupName=moby/moby |
| 50 | +RUN install-tool docker 20.10.7 |
| 51 | + |
| 52 | +# renovate: datasource=docker versioning=docker |
| 53 | +RUN install-tool node 20.10.0 |
| 54 | + |
| 55 | +# renovate: datasource=npm |
| 56 | +RUN install-tool corepack 0.23.0 |
| 57 | + |
| 58 | +# prepare some tools for gitpod |
| 59 | +RUN prepare-tool python |
| 60 | + |
| 61 | +USER gitpod |
0 commit comments