|
1 | | -FROM python:3.9-bullseye |
2 | | -LABEL maintainer="IETF Tools Team <tools-discuss@ietf.org>" |
3 | | - |
4 | | -ENV DEBIAN_FRONTEND=noninteractive |
5 | | -ENV NODE_MAJOR=16 |
6 | | - |
7 | | -# Update system packages |
8 | | -RUN apt-get update \ |
9 | | - && apt-get -qy upgrade \ |
10 | | - && apt-get -y install --no-install-recommends apt-utils dialog 2>&1 |
11 | | - |
12 | | -# Add Node.js Source |
13 | | -RUN apt-get install -y --no-install-recommends ca-certificates curl gnupg \ |
14 | | - && mkdir -p /etc/apt/keyrings\ |
15 | | - && curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg |
16 | | -RUN echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list |
17 | | - |
18 | | -# Add Docker Source |
19 | | -RUN curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg |
20 | | -RUN echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian \ |
21 | | - $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null |
22 | | - |
23 | | -# Add PostgreSQL Source |
24 | | -RUN echo "deb http://apt.postgresql.org/pub/repos/apt $(. /etc/os-release && echo "$VERSION_CODENAME")-pgdg main" | tee /etc/apt/sources.list.d/pgdg.list |
25 | | -RUN wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add - |
26 | | - |
27 | | -# Install the packages we need |
28 | | -RUN apt-get update --fix-missing && apt-get install -qy --no-install-recommends \ |
29 | | - apache2-utils \ |
30 | | - apt-file \ |
31 | | - bash \ |
32 | | - build-essential \ |
33 | | - curl \ |
34 | | - default-jdk \ |
35 | | - docker-ce-cli \ |
36 | | - enscript \ |
37 | | - firefox-esr \ |
38 | | - gawk \ |
39 | | - g++ \ |
40 | | - gcc \ |
41 | | - ghostscript \ |
42 | | - git \ |
43 | | - gnupg \ |
44 | | - jq \ |
45 | | - less \ |
46 | | - libcairo2-dev \ |
47 | | - libgtk2.0-0 \ |
48 | | - libgtk-3-0 \ |
49 | | - libnotify-dev \ |
50 | | - libgconf-2-4 \ |
51 | | - libgbm-dev \ |
52 | | - libnss3 \ |
53 | | - libxss1 \ |
54 | | - libasound2 \ |
55 | | - libxtst6 \ |
56 | | - libmagic-dev \ |
57 | | - libmariadb-dev \ |
58 | | - libmemcached-tools \ |
59 | | - locales \ |
60 | | - make \ |
61 | | - mariadb-client \ |
62 | | - memcached \ |
63 | | - nano \ |
64 | | - netcat \ |
65 | | - nodejs \ |
66 | | - pgloader \ |
67 | | - pigz \ |
68 | | - postgresql-client-14 \ |
69 | | - pv \ |
70 | | - python3-ipython \ |
71 | | - ripgrep \ |
72 | | - rsync \ |
73 | | - rsyslog \ |
74 | | - ruby \ |
75 | | - ruby-rubygems \ |
76 | | - unzip \ |
77 | | - wget \ |
78 | | - xauth \ |
79 | | - xvfb \ |
80 | | - yang-tools \ |
81 | | - zsh |
82 | | - |
83 | | -# Install kramdown-rfc2629 (ruby) |
84 | | -RUN gem install kramdown-rfc2629 |
85 | | - |
86 | | -# GeckoDriver |
87 | | -ARG GECKODRIVER_VERSION=latest |
88 | | -RUN GK_VERSION=$(if [ ${GECKODRIVER_VERSION:-latest} = "latest" ]; then echo "0.33.0"; else echo $GECKODRIVER_VERSION; fi) \ |
89 | | - && echo "Using GeckoDriver version: "$GK_VERSION \ |
90 | | - && wget --no-verbose -O /tmp/geckodriver.tar.gz https://github.com/mozilla/geckodriver/releases/download/v$GK_VERSION/geckodriver-v$GK_VERSION-linux64.tar.gz \ |
91 | | - && rm -rf /opt/geckodriver \ |
92 | | - && tar -C /opt -zxf /tmp/geckodriver.tar.gz \ |
93 | | - && rm /tmp/geckodriver.tar.gz \ |
94 | | - && mv /opt/geckodriver /opt/geckodriver-$GK_VERSION \ |
95 | | - && chmod 755 /opt/geckodriver-$GK_VERSION \ |
96 | | - && ln -fs /opt/geckodriver-$GK_VERSION /usr/bin/geckodriver |
97 | | - |
98 | | -# Activate Yarn |
99 | | -RUN corepack enable |
100 | | - |
101 | | -# Get rid of installation files we don't need in the image, to reduce size |
102 | | -RUN apt-get autoremove -y && apt-get clean -y && rm -rf /var/lib/apt/lists/* /var/cache/apt/* |
103 | | - |
104 | | -# "fake" dbus address to prevent errors |
105 | | -# https://github.com/SeleniumHQ/docker-selenium/issues/87 |
106 | | -ENV DBUS_SESSION_BUS_ADDRESS=/dev/null |
107 | | - |
108 | | -# avoid million NPM install messages |
109 | | -ENV npm_config_loglevel warn |
110 | | -# allow installing when the main user is root |
111 | | -ENV npm_config_unsafe_perm true |
112 | | -# disable NPM funding messages |
113 | | -ENV npm_config_fund false |
114 | | - |
115 | | -# Set locale to en_US.UTF-8 |
116 | | -RUN echo "LC_ALL=en_US.UTF-8" >> /etc/environment && \ |
117 | | - echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen && \ |
118 | | - echo "LANG=en_US.UTF-8" > /etc/locale.conf && \ |
119 | | - dpkg-reconfigure locales && \ |
120 | | - locale-gen en_US.UTF-8 && \ |
121 | | - update-locale LC_ALL en_US.UTF-8 |
122 | | -ENV LC_ALL en_US.UTF-8 |
123 | | - |
124 | | -# Install idnits |
125 | | -ADD https://raw.githubusercontent.com/ietf-tools/idnits-mirror/main/idnits /usr/local/bin/ |
126 | | -RUN chmod +rx /usr/local/bin/idnits |
127 | | - |
128 | | -# Turn off rsyslog kernel logging (doesn't work in Docker) |
129 | | -RUN sed -i '/imklog/s/^/#/' /etc/rsyslog.conf |
130 | | - |
131 | | -# Colorize the bash shell |
132 | | -RUN sed -i 's/#force_color_prompt=/force_color_prompt=/' /root/.bashrc |
133 | | - |
134 | | -# Turn off rsyslog kernel logging (doesn't work in Docker) |
135 | | -RUN sed -i '/imklog/s/^/#/' /etc/rsyslog.conf |
136 | | - |
137 | | -# Fetch wait-for utility |
138 | | -ADD https://raw.githubusercontent.com/eficode/wait-for/v2.1.3/wait-for /usr/local/bin/ |
139 | | -RUN chmod +rx /usr/local/bin/wait-for |
140 | | - |
141 | | -# Create assets directory |
142 | | -RUN mkdir -p /assets |
143 | | - |
144 | | -# Create workspace |
145 | | -RUN mkdir -p /workspace |
146 | | -WORKDIR /workspace |
| 1 | +FROM python:3.9-bullseye |
| 2 | +LABEL maintainer="IETF Tools Team <tools-discuss@ietf.org>" |
| 3 | + |
| 4 | +ENV DEBIAN_FRONTEND=noninteractive |
| 5 | +ENV NODE_MAJOR=16 |
| 6 | + |
| 7 | +# Update system packages |
| 8 | +RUN apt-get update \ |
| 9 | + && apt-get -qy upgrade \ |
| 10 | + && apt-get -y install --no-install-recommends apt-utils dialog 2>&1 |
| 11 | + |
| 12 | +# Add Node.js Source |
| 13 | +RUN apt-get install -y --no-install-recommends ca-certificates curl gnupg \ |
| 14 | + && mkdir -p /etc/apt/keyrings\ |
| 15 | + && curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg |
| 16 | +RUN echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list |
| 17 | + |
| 18 | +# Add Docker Source |
| 19 | +RUN curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg |
| 20 | +RUN echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian \ |
| 21 | + $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null |
| 22 | + |
| 23 | +# Add PostgreSQL Source |
| 24 | +RUN echo "deb http://apt.postgresql.org/pub/repos/apt $(. /etc/os-release && echo "$VERSION_CODENAME")-pgdg main" | tee /etc/apt/sources.list.d/pgdg.list |
| 25 | +RUN wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add - |
| 26 | + |
| 27 | +# Install the packages we need |
| 28 | +RUN apt-get update --fix-missing && apt-get install -qy --no-install-recommends \ |
| 29 | + apache2-utils \ |
| 30 | + apt-file \ |
| 31 | + bash \ |
| 32 | + build-essential \ |
| 33 | + curl \ |
| 34 | + default-jdk \ |
| 35 | + docker-ce-cli \ |
| 36 | + enscript \ |
| 37 | + firefox-esr \ |
| 38 | + gawk \ |
| 39 | + g++ \ |
| 40 | + gcc \ |
| 41 | + ghostscript \ |
| 42 | + git \ |
| 43 | + gnupg \ |
| 44 | + jq \ |
| 45 | + less \ |
| 46 | + libcairo2-dev \ |
| 47 | + libgtk2.0-0 \ |
| 48 | + libgtk-3-0 \ |
| 49 | + libnotify-dev \ |
| 50 | + libgconf-2-4 \ |
| 51 | + libgbm-dev \ |
| 52 | + libnss3 \ |
| 53 | + libxss1 \ |
| 54 | + libasound2 \ |
| 55 | + libxtst6 \ |
| 56 | + libmagic-dev \ |
| 57 | + libmariadb-dev \ |
| 58 | + libmemcached-tools \ |
| 59 | + locales \ |
| 60 | + make \ |
| 61 | + mariadb-client \ |
| 62 | + memcached \ |
| 63 | + nano \ |
| 64 | + netcat \ |
| 65 | + nodejs \ |
| 66 | + pgloader \ |
| 67 | + pigz \ |
| 68 | + postgresql-client-14 \ |
| 69 | + pv \ |
| 70 | + python3-ipython \ |
| 71 | + ripgrep \ |
| 72 | + rsync \ |
| 73 | + rsyslog \ |
| 74 | + ruby \ |
| 75 | + ruby-rubygems \ |
| 76 | + unzip \ |
| 77 | + wget \ |
| 78 | + xauth \ |
| 79 | + xvfb \ |
| 80 | + yang-tools \ |
| 81 | + zsh |
| 82 | + |
| 83 | +# Install kramdown-rfc2629 (ruby) |
| 84 | +RUN gem install kramdown-rfc2629 |
| 85 | + |
| 86 | +# GeckoDriver |
| 87 | +ARG GECKODRIVER_VERSION=latest |
| 88 | +RUN GK_VERSION=$(if [ ${GECKODRIVER_VERSION:-latest} = "latest" ]; then echo "0.34.0"; else echo $GECKODRIVER_VERSION; fi) \ |
| 89 | + && echo "Using GeckoDriver version: "$GK_VERSION \ |
| 90 | + && wget --no-verbose -O /tmp/geckodriver.tar.gz https://github.com/mozilla/geckodriver/releases/download/v$GK_VERSION/geckodriver-v$GK_VERSION-linux64.tar.gz \ |
| 91 | + && rm -rf /opt/geckodriver \ |
| 92 | + && tar -C /opt -zxf /tmp/geckodriver.tar.gz \ |
| 93 | + && rm /tmp/geckodriver.tar.gz \ |
| 94 | + && mv /opt/geckodriver /opt/geckodriver-$GK_VERSION \ |
| 95 | + && chmod 755 /opt/geckodriver-$GK_VERSION \ |
| 96 | + && ln -fs /opt/geckodriver-$GK_VERSION /usr/bin/geckodriver |
| 97 | + |
| 98 | +# Activate Yarn |
| 99 | +RUN corepack enable |
| 100 | + |
| 101 | +# Get rid of installation files we don't need in the image, to reduce size |
| 102 | +RUN apt-get autoremove -y && apt-get clean -y && rm -rf /var/lib/apt/lists/* /var/cache/apt/* |
| 103 | + |
| 104 | +# "fake" dbus address to prevent errors |
| 105 | +# https://github.com/SeleniumHQ/docker-selenium/issues/87 |
| 106 | +ENV DBUS_SESSION_BUS_ADDRESS=/dev/null |
| 107 | + |
| 108 | +# avoid million NPM install messages |
| 109 | +ENV npm_config_loglevel warn |
| 110 | +# allow installing when the main user is root |
| 111 | +ENV npm_config_unsafe_perm true |
| 112 | +# disable NPM funding messages |
| 113 | +ENV npm_config_fund false |
| 114 | + |
| 115 | +# Set locale to en_US.UTF-8 |
| 116 | +RUN echo "LC_ALL=en_US.UTF-8" >> /etc/environment && \ |
| 117 | + echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen && \ |
| 118 | + echo "LANG=en_US.UTF-8" > /etc/locale.conf && \ |
| 119 | + dpkg-reconfigure locales && \ |
| 120 | + locale-gen en_US.UTF-8 && \ |
| 121 | + update-locale LC_ALL en_US.UTF-8 |
| 122 | +ENV LC_ALL en_US.UTF-8 |
| 123 | + |
| 124 | +# Install idnits |
| 125 | +ADD https://raw.githubusercontent.com/ietf-tools/idnits-mirror/main/idnits /usr/local/bin/ |
| 126 | +RUN chmod +rx /usr/local/bin/idnits |
| 127 | + |
| 128 | +# Turn off rsyslog kernel logging (doesn't work in Docker) |
| 129 | +RUN sed -i '/imklog/s/^/#/' /etc/rsyslog.conf |
| 130 | + |
| 131 | +# Colorize the bash shell |
| 132 | +RUN sed -i 's/#force_color_prompt=/force_color_prompt=/' /root/.bashrc |
| 133 | + |
| 134 | +# Turn off rsyslog kernel logging (doesn't work in Docker) |
| 135 | +RUN sed -i '/imklog/s/^/#/' /etc/rsyslog.conf |
| 136 | + |
| 137 | +# Fetch wait-for utility |
| 138 | +ADD https://raw.githubusercontent.com/eficode/wait-for/v2.1.3/wait-for /usr/local/bin/ |
| 139 | +RUN chmod +rx /usr/local/bin/wait-for |
| 140 | + |
| 141 | +# Create assets directory |
| 142 | +RUN mkdir -p /assets |
| 143 | + |
| 144 | +# Create workspace |
| 145 | +RUN mkdir -p /workspace |
| 146 | +WORKDIR /workspace |
0 commit comments