@@ -19,7 +19,11 @@ ENV LC_ALL="en_US.UTF-8" \
19
19
LANG="en_US.UTF-8" \
20
20
LANGUAGE="en_US:en" \
21
21
TZ="Europe/Berlin" \
22
- DEBIAN_FRONTEND="noninteractive"
22
+ DEBIAN_FRONTEND="noninteractive" \
23
+ RESOURCES_PATH="/resources"
24
+
25
+ # Create resources folder
26
+ RUN mkdir $RESOURCES_PATH && chmod a+rwx $RESOURCES_PATH
23
27
24
28
# Install basics
25
29
# hadolint ignore=DL3005
@@ -36,6 +40,14 @@ RUN apt-get update --fix-missing \
36
40
git \
37
41
jq \
38
42
software-properties-common \
43
+ # Required by Pyenv
44
+ make \
45
+ build-essential \
46
+ libbz2-dev \
47
+ libssl-dev \
48
+ libreadline-dev \
49
+ libsqlite3-dev \
50
+ libffi-dev \
39
51
# Clean up
40
52
&& apt-get clean \
41
53
&& rm -rf /var/lib/apt/lists/*
@@ -77,10 +89,18 @@ RUN apt-get update \
77
89
pydocstyle==5.* \
78
90
isort==5.* \
79
91
docker==4.* \
92
+ nox==2020.8.* \
93
+ pipenv==2020.11.* \
80
94
# Clean up
81
95
&& apt-get clean \
82
96
&& rm -rf /var/lib/apt/lists/*
83
97
98
+ # Install pyenv to allow dynamic creation of python versions
99
+ RUN git clone https://github.com/pyenv/pyenv.git $RESOURCES_PATH/.pyenv
100
+ # Add pyenv to path
101
+ ENV PATH=$RESOURCES_PATH/.pyenv/shims:$RESOURCES_PATH/.pyenv/bin:$PATH \
102
+ PYENV_ROOT=$RESOURCES_PATH/.pyenv
103
+
84
104
# Install web development tools
85
105
RUN apt-get update \
86
106
&& curl -sL https://deb.nodesource.com/setup_12.x | bash - \
@@ -90,16 +110,23 @@ RUN apt-get update \
90
110
&& apt-get clean \
91
111
&& rm -rf /var/lib/apt/lists/*
92
112
93
- # Install documentation dependencies
94
- RUN pip install \
95
- mkdocs==1.* \
96
- mkdocs-material==6.* \
97
- pymdown-extensions==8.* \
98
- pygments==2.* \
99
- markdown-include==0.6.* \
100
- mkdocs-awesome-pages-plugin==2.* \
101
- mkdocs-markdownextradata-plugin==0.1.* \
102
- && npm install -g markdownlint@^0.21.1 markdownlint-cli@^0.24.0
113
+ # Install markdown lint tool
114
+ RUN npm install -g markdownlint@^0.21.1 markdownlint-cli@^0.24.0
115
+
116
+ # Workaround to get ssh working in act and github actions
117
+ RUN mkdir -p /github/home/.ssh/ \
118
+ # create empty config file if not exists
119
+ && touch /github/home/.ssh/config \
120
+ && chown -R root:root /github/home/.ssh \
121
+ && chmod 700 /github/home/.ssh \
122
+ && ln -s /github/home/.ssh /root/.ssh
123
+
124
+ # Settings and configurations
125
+ ENV \
126
+ # Flush log message immediately to stdout
127
+ PYTHONUNBUFFERED=true \
128
+ # Use local folder as pipenv virtualenv
129
+ PIPENV_VENV_IN_PROJECT=true
103
130
104
131
# Install Universal-Build
105
132
# hadolint ignore=DL3013
0 commit comments