@@ -3,6 +3,7 @@ FROM webdevops/php-apache
33ARG CI_DEPLOY_TOKEN
44ARG VANILLA_VERSION=3.3
55ARG ENV
6+ ARG BRANCH
67
78ENV TIDEWAYS_SERVICE vanilla
89ENV WEB_DOCUMENT_ROOT /vanillapp
@@ -15,33 +16,42 @@ RUN chmod -R 777 /vanillapp
1516
1617# Delete the auto-enabled 'stubcontent' plugin which adds stub contents
1718RUN rm -R /vanillapp/plugins/stubcontent
19+
20+ RUN echo "'$BRANCH' branch will be used for dependency repos ..."
21+
1822# Clone the forum-plugins repository
19- RUN git clone https://github.com/topcoder-platform/forums-plugins.git /tmp/forums-plugins
23+ RUN git clone --branch ${BRANCH} https://${CI_DEPLOY_TOKEN}@github.com/topcoder-platform/forums-plugins.git /tmp/forums-plugins
24+
25+ # Copy the Filestack plugin
26+ RUN git clone --branch ${BRANCH} https://${CI_DEPLOY_TOKEN}@github.com/topcoder-platform/forums-filestack-plugin /tmp/forums-plugins/Filestack
27+
28+ # Copy the Groups plugin
29+ RUN git clone --branch ${BRANCH} https://${CI_DEPLOY_TOKEN}@github.com/topcoder-platform/forums-groups-plugin /tmp/forums-plugins/Groups
30+
31+ # Copy the SumoLogic plugin
32+ RUN git clone --branch ${BRANCH} https://${CI_DEPLOY_TOKEN}@github.com/topcoder-platform/forums-sumologic-plugin /tmp/forums-plugins/Sumologic
33+
34+ # Copy the TopcoderEditor plugin
35+ RUN git clone --branch ${BRANCH} https://${CI_DEPLOY_TOKEN}@github.com/topcoder-platform/forums-topcoder-editor-plugin /tmp/forums-plugins/TopcoderEditor
36+
37+ # Copy the forum-theme repository
38+ RUN git clone --branch ${BRANCH} https://${CI_DEPLOY_TOKEN}@github.com/topcoder-platform/forums-theme.git /vanillapp/themes/topcoder
2039
2140# Remove DebugPlugin from PROD env
2241# RUN if [ "$ENV" = "prod" ]; \
2342# then rm -R /tmp/forums-plugins/DebugPlugin; \
2443# fi
2544
26- # Copy the Filestack plugin
27- RUN git clone https://${CI_DEPLOY_TOKEN}@github.com/topcoder-platform/forums-filestack-plugin /tmp/forums-plugins/Filestack
28-
29- # Copy the Groups plugin
30- RUN git clone https://${CI_DEPLOY_TOKEN}@github.com/topcoder-platform/forums-groups-plugin /tmp/forums-plugins/Groups
31-
32- # Copy the SumoLogic plugin
33- RUN git clone https://${CI_DEPLOY_TOKEN}@github.com/topcoder-platform/forums-sumologic-plugin /tmp/forums-plugins/Sumologic
34-
35- # Copy the TopcoderEditor plugin
36- RUN git clone https://${CI_DEPLOY_TOKEN}@github.com/topcoder-platform/forums-topcoder-editor-plugin /tmp/forums-plugins/TopcoderEditor
3745
3846# Copy all plugins to the Vanilla plugins folder
3947RUN cp -r /tmp/forums-plugins/. /vanillapp/plugins
4048
41- # Get the debug bar plugin
42- RUN wget https://us.v-cdn.net/5018160/uploads/addons/KSBIPJYMC0F2.zip
43- RUN unzip KSBIPJYMC0F2.zip
44- RUN cp -r debugbar /vanillapp/plugins
49+ # Get the debug bar plugin
50+ RUN if [ "$ENV" = "dev" ]; then \
51+ wget https://us.v-cdn.net/5018160/uploads/addons/KSBIPJYMC0F2.zip; \
52+ unzip KSBIPJYMC0F2.zip; \
53+ cp -r debugbar /vanillapp/plugins; \
54+ fi
4555
4656# Install Topcoder dependencies
4757RUN composer install --working-dir /vanillapp/plugins/Topcoder
@@ -58,8 +68,7 @@ COPY ./vanilla/. /vanillapp/.
5868# Set permissions on config file
5969RUN chown application:application /vanillapp/conf/config.php
6070RUN chmod ug=rwx,o=rx /vanillapp/conf/config.php
61- # Clone the forum-theme repository
62- RUN git clone 'https://github.com/topcoder-platform/forums-theme.git' /vanillapp/themes/topcoder
71+
6372
6473# Tideways
6574RUN if [ "$ENV" = "dev" ]; then \
0 commit comments