forked from dependabot/dependabot-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.development
42 lines (33 loc) · 1.19 KB
/
Dockerfile.development
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
ARG FROM_IMAGE=ghcr.io/dependabot/dependabot-updater-core
FROM $FROM_IMAGE
ARG ECOSYSTEM
# Temporarily switch to root user in order to install packages
USER root
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
vim \
strace \
ltrace \
gdb \
shellcheck \
# Required for updater/ development
libgit2-dev \
cmake \
pkg-config \
&& rm -rf /var/lib/apt/lists/*
USER dependabot
RUN curl -L -o ~/.vimrc https://github.com/hmarr/dotfiles/raw/main/vimrc-vanilla.vim && \
echo 'export PS1="[dependabot-core-dev] \w \[$(tput setaf 4)\]$ \[$(tput sgr 0)\]"' >> ~/.bashrc
WORKDIR $DEPENDABOT_HOME
RUN cd $ECOSYSTEM \
&& bundle config path ${DEPENDABOT_HOME}/omnibus/.bundle
RUN cd omnibus \
&& bundle install \
&& BUNDLE_BIN=.bundle/bin bundle binstubs --all \
&& rm .bundle/bin/bundle # let RubyGems manage Bundler
ENV PATH="${DEPENDABOT_HOME}/omnibus/.bundle/bin:$PATH"
# Create directory for volume containing VS Code extensions, to avoid reinstalling on image rebuilds
RUN mkdir -p ~/.vscode-server ~/.vscode-server-insiders
# Declare pass-thru environment variables used for debugging
ENV LOCAL_GITHUB_ACCESS_TOKEN="" \
LOCAL_CONFIG_VARIABLES=""