J'ai pu le lancer sur mon PC, ça semble fonctionner (accès à la webUI), mais j'ai pas cherché plus loin
Dockerfile :
FROM python:3.4.5-alpine
MAINTAINER Dryusdan <contact@dryusdan.fr>
ENV UID=991 GID=991 \
SECRET_KEY=ABCDEFGHIJKLMNOPQRSTUVWXYZ123456789 \
SALT=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz123456789 \
MAIL_SERVER= \
MAIL_PORT=465 \
MAIL_USERNAME= \
MAIL_PASSWORD= \
MAIL_TLS=false \
MAIL_SSL=true \
REDIS_URL=localhost \
REDIS_PORT=6379 \
MEMCACHED_SERVER=127.0.0.1:11211
RUN mkdir /Onyx \
&& BUILD_DEPS=" \
build-base \
cyrus-sasl-dev \
linux-headers \
libsasl \
libssl1.0 \
openssl-dev \
zlib-dev \
libffi \
python3-dev \
libmemcached-dev " \
&& apk --update add \
${BUILD_DEPS} \
su-exec \
curl \
git \
nodejs \
memcached \
openssl \
&& apk add --virtual python-software-properties \
&& pip3 install psutil python-memcached virtualenv setuptools pylibmc \
&& git clone https://github.com/OnyxProject/Onyx.git /Onyx && cd /Onyx/ && chmod +x launch.sh \
&& pip3 install -r requirements.txt \
&& cd /Onyx/ && make \
&& apk del ${BUILD_DEPS} \
&& rm -rf /var/cache/apk/* /tmp/* /root/.gnupg /root/.cache/ /Onyx/.git
WORKDIR /Onyx/
ADD config.py onyx/config.py
ADD start.sh start.sh
RUN chmod +x start.sh # && chown -R $UID:$GID /Onyx/
VOLUME /Onyx/data
EXPOSE 5080
ENTRYPOINT ["./start.sh"]
CMD ["python3", "manage.py", "runserver", "-h", "0.0.0.0", "-p", "5080", "-d", "-r"]
start.sh :
#!/bin/sh
addgroup -g ${GID} onyx && adduser -h /home/onyx -s /bin/sh -G onyx -u ${UID} -D onyx
sed -i -e 's|<secret_key>|'${SECRET_KEY}'|' \
-e 's|<salt>|'${SALT}'|' \
-e 's|<mail_server>|'${MAIL_SERVER}'|' \
-e 's|<mail_port>|'${MAIL_PORT}'|' \
-e 's|<mail_username>|'${MAIL_USERNAME}'|' \
-e 's|<mail_password>|'${MAIL_PASSWORD}'|' \
-e 's|<mail_tls>|'${MAIL_TLS}'|' \
-e 's|<mail_ssl>|'${MAIL_SSL}'|' \
-e 's|<redis_url>|'${REDIS_URL}'|' \
-e 's|<redis_port>|'${REDIS_PORT}'|' \
-e 's|<mecached_server>|'${MEMCACHED_SERVER}'|' /Onyx/onyx/config.py
chown -R $UID:$GID ./
if [ $# -eq 0 ]; then
exec su-exec onyx:onyx python3 manage.py runserver -h 0.0.0.0 -p 5080 -d -r
else
exec su-exec onyx:onyx $@
fi
Et comme tu peux voir, les droits sont ok :
$ winpty docker run -ti -p 5080:5080 xataz/onyx ls -l
total 108
-rw-r--r-- 1 onyx onyx 183 Dec 29 12:13 Dockerfile
-rwxr-xr-x 1 onyx onyx 2153 Dec 29 12:13 LICENSE.txt
-rw-r--r-- 1 onyx onyx 358 Dec 29 12:13 MANIFEST.in
-rw-r--r-- 1 onyx onyx 1645 Dec 29 12:13 Makefile
-rw-r--r-- 1 onyx onyx 1629 Dec 29 12:13 README.md
-rwxr-xr-x 1 onyx onyx 1024 Dec 29 12:13 README.rst
-rw-r--r-- 1 onyx onyx 1099 Dec 29 12:13 __init__.py
-rw-r--r-- 1 onyx onyx 178 Dec 29 12:13 apidoc.json
-rwxr-xr-x 1 onyx onyx 121 Dec 29 12:13 babel.cfg
drwxr-xr-x 2 onyx onyx 4096 Dec 29 12:25 data
drwxr-xr-x 12 onyx onyx 4096 Dec 29 12:25 doc
-rwxr-xr-x 1 onyx onyx 111 Dec 29 12:13 entry.py
-rw-r--r-- 1 onyx onyx 435 Dec 29 12:13 install.sh
-rw-r--r-- 1 onyx onyx 414 Dec 29 12:13 install_travis.sh
-rwxr-xr-x 1 onyx onyx 64 Dec 29 12:13 launch.sh
-rw-r--r-- 1 onyx onyx 100 Dec 29 12:13 launchUbuntu.sh
-rwxr-xr-x 1 onyx onyx 527 Dec 29 12:13 local.cfg
-rwxr-xr-x 1 onyx onyx 520 Dec 29 12:13 manage.py
drwxr-xr-x 18 onyx onyx 4096 Dec 29 12:25 onyx
-rwxr-xr-x 1 onyx onyx 227 Dec 29 12:13 packages.txt
-rwxr-xr-x 1 onyx onyx 472 Dec 29 12:13 requirements.txt
-rw-r--r-- 1 onyx onyx 64 Dec 29 12:13 run.sh
-rw-r--r-- 1 onyx onyx 111 Dec 29 12:13 run_travis.sh
-rwxr-xr-x 1 onyx onyx 37 Dec 29 12:13 run_vps.sh
-rwxr-xr-x 1 onyx onyx 797 Dec 29 12:19 start.sh
drwxr-xr-x 12 onyx onyx 4096 Dec 29 12:25 static
drwxr-xr-x 8 onyx onyx 4096 Dec 29 12:25 venv
Après comme dit, ne connaissant pas du tout l'appli, je n'ai pas testé plus.