-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile
More file actions
68 lines (51 loc) · 3.31 KB
/
Dockerfile
File metadata and controls
68 lines (51 loc) · 3.31 KB
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
FROM redmine:5.1.11
LABEL maintainer="EEA: IDM2 A-Team <eea-edw-a-team-alerts@googlegroups.com>"
ENV REDMINE_PATH=/usr/src/redmine \
REDMINE_LOCAL_PATH=/var/local/redmine
# Install dependencies and plugins
RUN apt-get update -q \
&& apt-get install -y --no-install-recommends build-essential unzip graphviz vim python3-pip cron rsyslog python3-setuptools systemctl \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* \
&& mkdir -p ${REDMINE_LOCAL_PATH}/github \
&& git clone https://github.com/tckz/redmine-wiki_graphviz_plugin.git ${REDMINE_PATH}/plugins/wiki_graphviz_plugin \
&& cd ${REDMINE_PATH}/plugins/wiki_graphviz_plugin \
&& git checkout 6da502f9a5eec94747aaaa7241b92370fa433de1 \
&& cd .. \
&& git clone -b 0.2.0 https://github.com/eea/redmine_wiki_backlinks.git ${REDMINE_PATH}/plugins/redmine_wiki_backlinks \
&& git clone -b 0.3.5 https://github.com/agileware-jp/redmine_banner.git ${REDMINE_PATH}/plugins/redmine_banner \
&& git clone -b 3.4.0 https://github.com/alphanodes/additionals.git ${REDMINE_PATH}/plugins/additionals \
&& git clone -b v1.5.1 https://github.com/mikitex70/redmine_drawio.git ${REDMINE_PATH}/plugins/redmine_drawio \
&& git clone -b 1.0.7 https://github.com/ncoders/redmine_local_avatars.git ${REDMINE_PATH}/plugins/redmine_local_avatars \
&& git clone -b 0.3.0 https://github.com/eea/redmine_xls_export.git ${REDMINE_PATH}/plugins/redmine_xls_export \
&& git clone https://github.com/eea/taskman.redmine.theme.git ${REDMINE_PATH}/public/themes/taskman.redmine.theme \
&& git clone -b master https://github.com/eea/redmine_entra_id.git ${REDMINE_PATH}/plugins/entra_id \
#&& git clone -b 1.11.0 https://github.com/haru/redmine_ai_helper.git ${REDMINE_PATH}/plugins/redmine_ai_helper \
&& chown -R redmine:redmine ${REDMINE_PATH} ${REDMINE_LOCAL_PATH}
# Install gems
RUN echo 'gem "dalli", "~> 2.7.6"' >> ${REDMINE_PATH}/Gemfile \
&& echo 'gem "acts-as-taggable-on", "~> 5.0"' >> ${REDMINE_PATH}/Gemfile
# Install eea cron tools
COPY crons/ ${REDMINE_LOCAL_PATH}/crons
COPY config/install_plugins.sh ${REDMINE_PATH}/install_plugins.sh
COPY plugins.cfg ${REDMINE_PATH}/plugins.cfg
# patches for plugins, to be removed when fixed
#wiki linkis "key not found" error
#Remove when fixed - https://github.com/bluezio/redmine_wiki_backlinks/issues/10
COPY patches/wiki_links_controller.rb ${REDMINE_PATH}/plugins/redmine_wiki_backlinks/app/controllers/wiki_links_controller.rb
COPY redmine_jobs /var/redmine_jobs.txt
RUN sed -i '/#cron./c\cron.* \/proc\/1\/fd\/1' /etc/rsyslog.conf \
&& sed -i '/cron./c\cron.* \/proc\/1\/fd\/1' /etc/rsyslog.conf \
&& sed -i 's/-\/var\/log\/syslog/\/proc\/1\/fd\/1/g' /etc/rsyslog.conf \
&& systemctl enable rsyslog
RUN echo "export REDMINE_PATH=$REDMINE_PATH\nexport BUNDLE_PATH=$BUNDLE_PATH\nexport BUNDLE_APP_CONFIG=$BUNDLE_PATH\nexport PATH=$BUNDLE_PATH/bin:$PATH" > ${REDMINE_PATH}/.profile \
&& chown redmine:redmine ${REDMINE_PATH}/.profile \
&& usermod -d ${REDMINE_PATH} redmine
# Send Redmine logs on STDOUT/STDERR
COPY config/additional_environment.rb ${REDMINE_PATH}/config/additional_environment.rb
# Add email configuration
COPY config/configuration.yml ${REDMINE_PATH}/config/configuration.yml
COPY start_redmine.sh /start_redmine.sh
RUN chmod 0766 /start_redmine.sh
ENTRYPOINT ["/start_redmine.sh"]
CMD []