diff --git a/Dockerfile b/Dockerfile index 15269a9..c85e032 100644 --- a/Dockerfile +++ b/Dockerfile @@ -35,11 +35,12 @@ ADD run-document-server.sh /app/onlyoffice/run-document-server.sh EXPOSE 80 443 ARG REPO_URL="deb http://static.teamlab.com/repo/debian/ squeeze main" +ARG PRODUCT_NAME=onlyoffice-documentserver RUN echo "$REPO_URL" | tee /etc/apt/sources.list.d/onlyoffice.list && \ apt-get -y update && \ service postgresql start && \ - apt-get --force-yes -yq install onlyoffice-documentserver && \ + apt-get --force-yes -yq install $PRODUCT_NAME && \ service postgresql stop && \ service supervisor stop && \ chmod 755 /app/onlyoffice/*.sh && \ diff --git a/Makefile b/Makefile index 724126d..eac2ccb 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ PACKAGE_VERSION := $(PRODUCT_VERSION)-$(BUILD_NUMBER) -REPO_URL := "deb http://repo-doc-onlyoffice-com.s3.amazonaws.com/ubuntu/trusty/onlyoffice-documentserver/$(GIT_BRANCH)/$(PACKAGE_VERSION)/ repo/" +REPO_URL := "deb http://repo-doc-onlyoffice-com.s3.amazonaws.com/ubuntu/trusty/$(PRODUCT_NAME)/$(GIT_BRANCH)/$(PACKAGE_VERSION)/ repo/" ifeq ($(GIT_BRANCH), origin/develop) DOCKER_TAGS += $(subst -,.,$(PACKAGE_VERSION)) @@ -18,7 +18,7 @@ DOCKER_TARGETS := $(foreach TAG,$(DOCKER_TAGS),$(DOCKER_REPO)$(COLON)$(TAG)) $(DOCKER_TARGETS): $(DEB_REPO_DATA) - sudo docker build --build-arg REPO_URL=$(REPO_URL) -t $(subst $(COLON),:,$@) . &&\ + sudo docker build --build-arg REPO_URL=$(REPO_URL) --build-arg PRODUCT_NAME=$(PRODUCT_NAME) -t $(subst $(COLON),:,$@) . &&\ mkdir -p $$(dirname $@) &&\ echo "Done" > $@