From fcbecd9bb8b450e748c077c0423c3044582879a1 Mon Sep 17 00:00:00 2001 From: Pedro Salgado Date: Fri, 30 Dec 2016 15:46:52 -0700 Subject: [PATCH] 10.0/Dockerfile: split into base/Dockerfile and Dockerfile.release. --- 10.0/Dockerfile | 55 ----------------------------------------- 10.0/Dockerfile.release | 36 +++++++++++++++++++++++++++ 10.0/base/Dockerfile | 25 +++++++++++++++++++ 3 files changed, 61 insertions(+), 55 deletions(-) delete mode 100644 10.0/Dockerfile create mode 100644 10.0/Dockerfile.release create mode 100644 10.0/base/Dockerfile diff --git a/10.0/Dockerfile b/10.0/Dockerfile deleted file mode 100644 index 083ffac..0000000 --- a/10.0/Dockerfile +++ /dev/null @@ -1,55 +0,0 @@ -FROM debian:jessie -MAINTAINER Odoo S.A. - -# Install some deps, lessc and less-plugin-clean-css, and wkhtmltopdf -RUN set -x; \ - apt-get update \ - && apt-get install -y --no-install-recommends \ - ca-certificates \ - curl \ - node-less \ - python-gevent \ - python-pip \ - python-pyinotify \ - python-renderpm \ - python-support \ - && curl -o wkhtmltox.deb -SL http://nightly.odoo.com/extra/wkhtmltox-0.12.1.2_linux-jessie-amd64.deb \ - && echo '40e8b906de658a2221b15e4e8cd82565a47d7ee8 wkhtmltox.deb' | sha1sum -c - \ - && dpkg --force-depends -i wkhtmltox.deb \ - && apt-get -y install -f --no-install-recommends \ - && apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false -o APT::AutoRemove::SuggestsImportant=false npm \ - && rm -rf /var/lib/apt/lists/* wkhtmltox.deb \ - && pip install psycogreen==1.0 - -# Install Odoo -ENV ODOO_VERSION 10.0 -ENV ODOO_RELEASE 20161123 -RUN set -x; \ - curl -o odoo.deb -SL http://nightly.odoo.com/${ODOO_VERSION}/nightly/deb/odoo_${ODOO_VERSION}.${ODOO_RELEASE}_all.deb \ - && echo '3c9edd6f1b5673c2a87fe65cfa5f404ef5f9c8e7 odoo.deb' | sha1sum -c - \ - && dpkg --force-depends -i odoo.deb \ - && apt-get update \ - && apt-get -y install -f --no-install-recommends \ - && rm -rf /var/lib/apt/lists/* odoo.deb - -# Copy entrypoint script and Odoo configuration file -COPY ./entrypoint.sh / -COPY ./odoo.conf /etc/odoo/ -RUN chown odoo /etc/odoo/odoo.conf - -# Mount /var/lib/odoo to allow restoring filestore and /mnt/extra-addons for users addons -RUN mkdir -p /mnt/extra-addons \ - && chown -R odoo /mnt/extra-addons -VOLUME ["/var/lib/odoo", "/mnt/extra-addons"] - -# Expose Odoo services -EXPOSE 8069 8071 - -# Set the default config file -ENV ODOO_RC /etc/odoo/odoo.conf - -# Set default user when running the container -USER odoo - -ENTRYPOINT ["/entrypoint.sh"] -CMD ["odoo"] diff --git a/10.0/Dockerfile.release b/10.0/Dockerfile.release new file mode 100644 index 0000000..a24bd34 --- /dev/null +++ b/10.0/Dockerfile.release @@ -0,0 +1,36 @@ +FROM steenzout/odoo:${ODOO_VERSION}-base +MAINTAINER Pedro Salgado "steenzout@ymail.com" + +ENV ODOO_RELEASE ${ODOO_RELEASE} +ENV ODOO_SHA1SUM ${ODOO_SHA1SUM} + +# Set the default config file +ENV ODOO_RC /etc/odoo/odoo.conf + +# Install Odoo +RUN set -x; \ + curl -o odoo.deb -SL http://nightly.odoo.com/${ODOO_VERSION}/nightly/deb/odoo_${ODOO_VERSION}.${ODOO_RELEASE}_all.deb \ + && echo "${ODOO_SHA1SUM} odoo.deb" | sha1sum -c - \ + && dpkg --force-depends -i odoo.deb \ + && apt-get update \ + && apt-get -y install -f --no-install-recommends \ + && rm -rf /var/lib/apt/lists/* odoo.deb + +# Copy entrypoint script and Odoo configuration file +COPY "${ODOO_VERSION}/entrypoint.sh" / +COPY "${ODOO_VERSION}/odoo.conf" /etc/odoo/ +RUN chown odoo /etc/odoo/odoo.conf + +# Mount /var/lib/odoo to allow restoring filestore and /mnt/extra-addons for users addons +RUN mkdir -p /mnt/extra-addons \ + && chown -R odoo /mnt/extra-addons +VOLUME ["/var/lib/odoo", "/mnt/extra-addons"] + +# Expose Odoo services +EXPOSE 8069 8071 + +# Set default user when running the container +USER odoo + +ENTRYPOINT ["/entrypoint.sh"] +CMD ["odoo"] diff --git a/10.0/base/Dockerfile b/10.0/base/Dockerfile new file mode 100644 index 0000000..cc6daca --- /dev/null +++ b/10.0/base/Dockerfile @@ -0,0 +1,25 @@ +FROM debian:jessie +MAINTAINER Odoo S.A. + +ENV WKHTMLTOX_SHA1SUM 40e8b906de658a2221b15e4e8cd82565a47d7ee8 +ENV WKHTMLTOX_VERSION 0.12.1.2 + +# Install some deps, lessc and less-plugin-clean-css, and wkhtmltopdf +RUN set -x; \ + apt-get update \ + && apt-get install -y --no-install-recommends \ + ca-certificates \ + curl \ + node-less \ + python-gevent \ + python-pip \ + python-pyinotify \ + python-renderpm \ + python-support \ + && curl -o wkhtmltox.deb -SL "http://nightly.odoo.com/extra/wkhtmltox-${WKHTMLTOX_VERSION}_linux-jessie-amd64.deb" \ + && echo "${WKHTMLTOX_SHA1SUM} wkhtmltox.deb" | sha1sum -c - \ + && dpkg --force-depends -i wkhtmltox.deb \ + && apt-get -y install -f --no-install-recommends \ + && apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false -o APT::AutoRemove::SuggestsImportant=false npm \ + && rm -rf /var/lib/apt/lists/* wkhtmltox.deb \ + && pip install psycogreen==1.0