docker-odoo/9.0/Dockerfile.release

37 lines
1.2 KiB
Docker
Raw Normal View History

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 OPENERP_SERVER /etc/odoo/openerp-server.conf
# Install Odoo
RUN set -x; \
curl -o odoo.deb -SL http://nightly.odoo.com/${ODOO_VERSION}/nightly/deb/odoo_${ODOO_VERSION}c.${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}/openerp-server.conf" /etc/odoo/openerp-server.conf
RUN chown odoo /etc/odoo/openerp-server.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 ["openerp-server"]