From e14b97bd76d8162b1d605c63ac8d3a5adad95dee Mon Sep 17 00:00:00 2001 From: Alexey Golubev Date: Fri, 26 Aug 2016 13:39:29 +0300 Subject: [PATCH] Create db and user before install documentserver --- Dockerfile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Dockerfile b/Dockerfile index 0ebc2e1..70aa8ee 100644 --- a/Dockerfile +++ b/Dockerfile @@ -20,6 +20,9 @@ RUN echo "#!/bin/sh\nexit 0" > /usr/sbin/policy-rc.d && \ add-apt-repository ppa:ubuntu-toolchain-r/test && \ apt-get -y update && \ apt-get --force-yes -yq install software-properties-common adduser postgresql redis-server rabbitmq-server nginx-extras nodejs libstdc++6 libcurl3 libxml2 libboost-regex-dev zlib1g supervisor fonts-dejavu fonts-liberation ttf-mscorefonts-installer fonts-crosextra-carlito fonts-takao-gothic fonts-opensymbol libxss1 libgtkglext1 libcairo2 xvfb libxtst6 libgconf2-4 libasound2 bomstrip libnspr4 libnss3 libnss3-nssdb nano htop && \ + sudo -u postgres psql -c "CREATE DATABASE onlyoffice;" && \ + sudo -u postgres psql -c "CREATE USER onlyoffice WITH password 'onlyoffice';" && \ + sudo -u postgres psql -c "GRANT ALL privileges ON DATABASE onlyoffice TO onlyoffice;" && \ service postgresql stop && \ service redis-server stop && \ service rabbitmq-server stop && \