Make SelfOSS available on port 80 on host side

This commit is contained in:
Jean Baptiste Favre 2016-06-28 19:24:10 +02:00
parent 9a88f5876c
commit 212576fd06
2 changed files with 4 additions and 4 deletions

View File

@ -16,9 +16,8 @@ RUN /usr/bin/apt-get update -yqq \
&& /bin/rm /bin/sh && ln -s /bin/bash /bin/sh \
&& /usr/sbin/groupadd -r selfoss \
&& /usr/sbin/useradd -r -m -s /bin/bash -g selfoss selfoss \
&& /usr/bin/curl -L -o /tmp/selfoss.tar.gz https://github.com/SSilence/selfoss/archive/2.15.tar.gz
RUN /bin/su - selfoss -c '/bin/tar xzf /tmp/selfoss.tar.gz -C /home/selfoss --strip-components=1' \
&& /usr/bin/curl -L -o /tmp/selfoss.tar.gz https://github.com/SSilence/selfoss/archive/2.15.tar.gz \
&& /bin/su - selfoss -c '/bin/tar xzf /tmp/selfoss.tar.gz -C /home/selfoss --strip-components=1' \
&& /bin/rm -f /tmp/selfoss.tar.gz \
&& /bin/rm -f /home/selfoss/selfoss*.zip \
&& /bin/mkdir /var/lib/selfoss \
@ -27,7 +26,7 @@ RUN /bin/su - selfoss -c '/bin/tar xzf /tmp/selfoss.tar.gz -C /home/selfoss --st
VOLUME /var/lib/selfoss
ENTRYPOINT ["/usr/local/bin/docker-entrypoint.sh"]
ADD ./docker-entrypoint.sh /usr/local/bin
ADD ./docker-entrypoint.sh /usr/local/bin/
ADD ./run.php /home/selfoss/
EXPOSE 8080

View File

@ -29,6 +29,7 @@ if (php_sapi_name() == 'cli-server') {
// taken from cli arg, hack for updater
$_SERVER["SERVER_ADDR"] = '127.0.0.1';
$_SERVER["SERVER_NAME"] = '127.0.0.1';
$_SERVER["SERVER_PORT"] = '80';
require("index.php");
}