Compare commits
4 Commits
7d47280ac6
...
master
Author | SHA1 | Date | |
---|---|---|---|
d6c1dc77f2 | |||
87652566c1 | |||
c8f39f4ffa | |||
c33d4a1f50 |
@@ -6,12 +6,19 @@ MAINTAINER Adrian Malacoda <adrian.malacoda@monarch-pass.net>
|
|||||||
|
|
||||||
WORKDIR /
|
WORKDIR /
|
||||||
|
|
||||||
|
# Install composer
|
||||||
|
RUN apt-get -y update && apt-get install -y --no-install-recommends git zip
|
||||||
|
RUN curl --silent --show-error https://getcomposer.org/installer | php && \
|
||||||
|
chmod +x composer.phar && mv composer.phar /usr/local/bin/composer
|
||||||
|
|
||||||
# Install extensions
|
# Install extensions
|
||||||
ADD add_extension.sh /add_extension.sh
|
ADD add_extension.sh /add_extension.sh
|
||||||
RUN chmod +x add_extension.sh
|
RUN chmod +x add_extension.sh
|
||||||
RUN ./add_extension.sh Scribunto $MEDIAWIKI_BRANCH && \
|
RUN ./add_extension.sh Scribunto $MEDIAWIKI_BRANCH && \
|
||||||
./add_extension.sh VisualEditor $MEDIAWIKI_BRANCH
|
./add_extension.sh VisualEditor $MEDIAWIKI_BRANCH
|
||||||
|
|
||||||
|
ADD https://raw.githubusercontent.com/vishnubob/wait-for-it/master/wait-for-it.sh /wait-for-it
|
||||||
ADD setup.sh /setup.sh
|
ADD setup.sh /setup.sh
|
||||||
RUN chmod +x /setup.sh
|
ADD get-variable /get-variable
|
||||||
|
RUN chmod +x setup.sh && chmod +x wait-for-it && chmod +x get-variable
|
||||||
CMD ["/setup.sh"]
|
CMD ["/setup.sh"]
|
||||||
|
10
get-variable
Normal file
10
get-variable
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
#!/usr/bin/env php
|
||||||
|
<?php
|
||||||
|
define("MEDIAWIKI", 1);
|
||||||
|
define("HTML_ROOT", "/var/www/html");
|
||||||
|
|
||||||
|
function wfLoadSkin() {}
|
||||||
|
function wfLoadExtension() {}
|
||||||
|
|
||||||
|
@include HTML_ROOT . "/LocalSettings.php";
|
||||||
|
print_r($GLOBALS[$argv[1]]);
|
2
setup.sh
2
setup.sh
@@ -5,6 +5,8 @@ HTML_ROOT=/var/www/html
|
|||||||
# Run updater if we have an existing install
|
# Run updater if we have an existing install
|
||||||
if [[ -e "$HTML_ROOT/LocalSettings.php" ]]; then
|
if [[ -e "$HTML_ROOT/LocalSettings.php" ]]; then
|
||||||
cd "$HTML_ROOT/maintenance"
|
cd "$HTML_ROOT/maintenance"
|
||||||
|
DB_SERVER=$(/get-variable wgDBserver)
|
||||||
|
/wait-for-it "$DB_SERVER:3306"
|
||||||
php update.php
|
php update.php
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user