Skip to content

Commit

Permalink
feat: optimize for wider usage
Browse files Browse the repository at this point in the history
  • Loading branch information
viceice committed Nov 30, 2023
1 parent a8b183e commit 80ca6df
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 7 deletions.
23 changes: 16 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,20 @@ COPY --from=containerbase /usr/local/bin/ /usr/local/bin/
COPY --from=containerbase /usr/local/containerbase/ /usr/local/containerbase/
RUN install-containerbase

# add required gitpod packages
# add required gitpod and other system packages
RUN set -ex; \
install-apt make shellcheck sudo locales; \
install-apt \
g++ \
locales \
make \
shellcheck \
sudo \
; \
locale-gen en_US.UTF-8; \
true

# allow sudo without password
RUN echo "gitpod ALL=NOPASSWD:ALL" > /etc/sudoers.d/gitpod; sudo id
RUN echo "$USER_NAME ALL=NOPASSWD:ALL" > /etc/sudoers.d/$USER_NAME; sudo id

# renovate: datasource=github-tags packageName=git/git
RUN install-tool git v2.43.0
Expand All @@ -52,10 +58,13 @@ RUN install-tool docker v24.0.7
# renovate: datasource=github-releases packageName=containerbase/node-prebuild versioning=node
RUN install-tool node 20.10.0

# renovate: datasource=npm
RUN install-tool corepack 0.23.0
# enable buildin corepack
RUN corepack enable

# renovate: datasource=github-releases packageName=containerbase/python-prebuild
RUN install-tool python 3.12.0

# prepare some tools for gitpod
RUN prepare-tool python
#RUN prepare-tool python

USER gitpod
USER $USER_NAME
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,18 @@ A docker base image for Gitpod usage.

This repository is the source for the Github container registry image [`ghcr.io/containerbase/gitpod`](https://github.com/containerbase/gitpod/pkgs/container/gitpod).
Commits to `main` branch are automatically build and published.

This image allows `sudo` without password.
It's setting all directiories as safe for git.

Additional installed packages:

- docker
- git
- g++
- make
- nodejs (corepack enabled)
- locales
- python
- shellcheck
- sudo

0 comments on commit 80ca6df

Please sign in to comment.