-
-
Notifications
You must be signed in to change notification settings - Fork 13
/
Dockerfile
96 lines (79 loc) · 2.25 KB
/
Dockerfile
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
ARG IMAGE=ubuntu
ARG VERSION=22.04
FROM ${IMAGE}:${VERSION}
ARG DISTRO=ubuntu
ARG USERNAME=developer
ARG USER_UID=1000
ARG USER_GID=1000
ARG DEBIAN_FRONTEND=noninteractive
ARG NVM_VERSION=0.39.7
ENV LC_ALL=C.UTF-8
LABEL maintainer="Madalin Ignisca"
LABEL version="8.0.0"
LABEL description="Development environment for the joy and pleasure of web developers"
LABEL repo="https://github.com/madalinignisca/devcontainers"
ADD unminimize /tmp/unminimize
RUN chmod 700 /tmp/unminimize \
&& /tmp/unminimize
RUN groupadd --gid ${USER_GID} ${USERNAME} \
&& useradd --create-home --shell /bin/bash --uid ${USER_UID} --gid ${USER_GID} ${USERNAME}
RUN apt-get update \
&& apt-get upgrade -y \
&& apt-get install -y \
bind9-dnsutils \
ca-certificates \
curl \
gnupg \
lsb-release \
openssl \
software-properties-common \
bash-completion \
build-essential \
ffmpeg \
gettext-base \
git \
htop \
jq \
language-pack-en \
less \
lsof \
man-db \
manpages \
mariadb-client \
mc \
nano \
net-tools \
openssh-client \
postgresql-client \
procps \
psmisc \
redis-tools \
rsync \
sqlite3 \
sudo \
time \
unzip \
wget \
whois \
zip
RUN echo "${USERNAME} ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/${USERNAME} \
&& chmod 0440 /etc/sudoers.d/${USERNAME}
RUN mkdir -p /workspace \
&& chown ${USERNAME}:${USERNAME} /workspace
ADD .editorconfig /home/${USERNAME}
RUN chown ${USERNAME}:${USERNAME} /home/${USERNAME}/.editorconfig
HEALTHCHECK NONE
ENV LANG en_US.utf8
USER ${USERNAME}
COPY bashprompt /tmp/bashprompt
RUN cat /tmp/bashprompt >> /home/${USERNAME}/.bashrc
RUN mkdir -p /home/${USERNAME}/.local \
&& echo "export PROMPT_COMMAND='history -a'" >> "/home/${USERNAME}/.bashrc" \
&& echo "export HISTFILE=/home/${USERNAME}/.local/bash_history" >> "/home/${USERNAME}/.bashrc"
RUN mkdir -p /home/${USERNAME}/.cache
RUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v${NVM_VERSION}/install.sh | bash \
&& mkdir /home/${USERNAME}/.nvm/versions
VOLUME /workspace
VOLUME /home/${USERNAME}/.cache
VOLUME /home/${USERNAME}/.nvm/versions
WORKDIR /workspace