diff --git a/CHANGELOG.md b/CHANGELOG.md index dd654582b..8ef9953c4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,7 @@ * `jan` * added new `jira` releases * added new `bitbucket` releases + * added new `confluence` releases ------------------------------------------------------------------- ## 2022 * `dec` diff --git a/Makefile b/Makefile index 5eaea22e3..18d621a14 100644 --- a/Makefile +++ b/Makefile @@ -546,6 +546,18 @@ bundle-atlassian: cd `pwd`/linux/ecosystem/atlassian/bitbucket/8.6.1 && pwd && make build && make deploy cd `pwd`/linux/ecosystem/atlassian/bitbucket/8.7.0 && pwd && make build && make deploy cd `pwd`/linux/ecosystem/atlassian/confluence/latest && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/7.19.0 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/7.19.1 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/7.19.2 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/7.19.3 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/7.19.4 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/7.20.0 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/7.20.1 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/7.20.2 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/7.20.3 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/8.0.0 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/8.0.1 && pwd && make build && make deploy + cd `pwd`/linux/ecosystem/atlassian/confluence/8.0.2 && pwd && make build && make deploy # cd `pwd`/linux/ecosystem/atlassian/crucible/latest && pwd && make build && make deploy # cd `pwd`/linux/ecosystem/atlassian/fisheye/latest && pwd && make build && make deploy cd `pwd`/linux/ecosystem/atlassian/fisheye-crucible/latest && pwd && make build && make deploy diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.0/Dockerfile b/linux/ecosystem/atlassian/confluence/7/7.19.0/Dockerfile new file mode 100644 index 000000000..5578451b7 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.0/Dockerfile @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.0 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.0/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/7/7.19.0/Dockerfile.jdk11 new file mode 100644 index 000000000..fef988fcb --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.0/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.0 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.0/Makefile b/linux/ecosystem/atlassian/confluence/7/7.19.0/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.0/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.0/docker-compose.yml b/linux/ecosystem/atlassian/confluence/7/7.19.0/docker-compose.yml new file mode 100644 index 000000000..fb28f33b4 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.0/docker-compose.yml @@ -0,0 +1,11 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:7.19.0" + build: + context: . + app-jdk11: + image: "epicmorg/confluence:7.19.0-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.0/entrypoint.sh b/linux/ecosystem/atlassian/confluence/7/7.19.0/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.0/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.1/Dockerfile b/linux/ecosystem/atlassian/confluence/7/7.19.1/Dockerfile new file mode 100644 index 000000000..831f8687e --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.1/Dockerfile @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.1 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.1/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/7/7.19.1/Dockerfile.jdk11 new file mode 100644 index 000000000..a8ab599ca --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.1/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.1 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.1/Makefile b/linux/ecosystem/atlassian/confluence/7/7.19.1/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.1/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.1/docker-compose.yml b/linux/ecosystem/atlassian/confluence/7/7.19.1/docker-compose.yml new file mode 100644 index 000000000..2be28a129 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.1/docker-compose.yml @@ -0,0 +1,11 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:7.19.1" + build: + context: . + app-jdk11: + image: "epicmorg/confluence:7.19.1-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.1/entrypoint.sh b/linux/ecosystem/atlassian/confluence/7/7.19.1/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.1/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.2/Dockerfile b/linux/ecosystem/atlassian/confluence/7/7.19.2/Dockerfile new file mode 100644 index 000000000..d1a580d49 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.2/Dockerfile @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.2 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.2/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/7/7.19.2/Dockerfile.jdk11 new file mode 100644 index 000000000..4cea64d9e --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.2/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.2 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.2/Makefile b/linux/ecosystem/atlassian/confluence/7/7.19.2/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.2/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.2/docker-compose.yml b/linux/ecosystem/atlassian/confluence/7/7.19.2/docker-compose.yml new file mode 100644 index 000000000..7a9d09f83 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.2/docker-compose.yml @@ -0,0 +1,11 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:7.19.2" + build: + context: . + app-jdk11: + image: "epicmorg/confluence:7.19.2-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.2/entrypoint.sh b/linux/ecosystem/atlassian/confluence/7/7.19.2/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.2/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.3/Dockerfile b/linux/ecosystem/atlassian/confluence/7/7.19.3/Dockerfile new file mode 100644 index 000000000..6a781643a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.3/Dockerfile @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.3 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.3/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/7/7.19.3/Dockerfile.jdk11 new file mode 100644 index 000000000..d85e8965e --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.3/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.3 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.3/Makefile b/linux/ecosystem/atlassian/confluence/7/7.19.3/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.3/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.3/docker-compose.yml b/linux/ecosystem/atlassian/confluence/7/7.19.3/docker-compose.yml new file mode 100644 index 000000000..3b1ff79a0 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.3/docker-compose.yml @@ -0,0 +1,11 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:7.19.3" + build: + context: . + app-jdk11: + image: "epicmorg/confluence:7.19.3-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.3/entrypoint.sh b/linux/ecosystem/atlassian/confluence/7/7.19.3/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.3/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.4/Dockerfile b/linux/ecosystem/atlassian/confluence/7/7.19.4/Dockerfile new file mode 100644 index 000000000..fff4f2585 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.4/Dockerfile @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.4 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.4/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/7/7.19.4/Dockerfile.jdk11 new file mode 100644 index 000000000..d5d93e715 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.4/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.4 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.4/Makefile b/linux/ecosystem/atlassian/confluence/7/7.19.4/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.4/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.4/docker-compose.yml b/linux/ecosystem/atlassian/confluence/7/7.19.4/docker-compose.yml new file mode 100644 index 000000000..3a914ba6d --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.4/docker-compose.yml @@ -0,0 +1,11 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:7.19.4" + build: + context: . + app-jdk11: + image: "epicmorg/confluence:7.19.4-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 diff --git a/linux/ecosystem/atlassian/confluence/7/7.19.4/entrypoint.sh b/linux/ecosystem/atlassian/confluence/7/7.19.4/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.19.4/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.0/Dockerfile b/linux/ecosystem/atlassian/confluence/7/7.20.0/Dockerfile new file mode 100644 index 000000000..456fb5305 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.0/Dockerfile @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.20.0 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.0/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/7/7.20.0/Dockerfile.jdk11 new file mode 100644 index 000000000..429736f49 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.0/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.20.0 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.0/Makefile b/linux/ecosystem/atlassian/confluence/7/7.20.0/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.0/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.0/docker-compose.yml b/linux/ecosystem/atlassian/confluence/7/7.20.0/docker-compose.yml new file mode 100644 index 000000000..f7058b151 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.0/docker-compose.yml @@ -0,0 +1,11 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:7.20.0" + build: + context: . + app-jdk11: + image: "epicmorg/confluence:7.20.0-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.0/entrypoint.sh b/linux/ecosystem/atlassian/confluence/7/7.20.0/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.0/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.1/Dockerfile b/linux/ecosystem/atlassian/confluence/7/7.20.1/Dockerfile new file mode 100644 index 000000000..b8ecd4eb2 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.1/Dockerfile @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.20.1 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.1/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/7/7.20.1/Dockerfile.jdk11 new file mode 100644 index 000000000..328841c95 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.1/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.20.1 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.1/Makefile b/linux/ecosystem/atlassian/confluence/7/7.20.1/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.1/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.1/docker-compose.yml b/linux/ecosystem/atlassian/confluence/7/7.20.1/docker-compose.yml new file mode 100644 index 000000000..d7abb3ebb --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.1/docker-compose.yml @@ -0,0 +1,11 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:7.20.1" + build: + context: . + app-jdk11: + image: "epicmorg/confluence:7.20.1-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.1/entrypoint.sh b/linux/ecosystem/atlassian/confluence/7/7.20.1/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.1/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.2/Dockerfile b/linux/ecosystem/atlassian/confluence/7/7.20.2/Dockerfile new file mode 100644 index 000000000..45155e90e --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.2/Dockerfile @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.20.2 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.2/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/7/7.20.2/Dockerfile.jdk11 new file mode 100644 index 000000000..d57f79ff5 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.2/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.20.2 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.2/Makefile b/linux/ecosystem/atlassian/confluence/7/7.20.2/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.2/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.2/docker-compose.yml b/linux/ecosystem/atlassian/confluence/7/7.20.2/docker-compose.yml new file mode 100644 index 000000000..20c789170 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.2/docker-compose.yml @@ -0,0 +1,11 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:7.20.2" + build: + context: . + app-jdk11: + image: "epicmorg/confluence:7.20.2-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.2/entrypoint.sh b/linux/ecosystem/atlassian/confluence/7/7.20.2/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.2/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.3/Dockerfile b/linux/ecosystem/atlassian/confluence/7/7.20.3/Dockerfile new file mode 100644 index 000000000..483be57bf --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.3/Dockerfile @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.20.3 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.3/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/7/7.20.3/Dockerfile.jdk11 new file mode 100644 index 000000000..a7d3a49ef --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.3/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.20.3 +ARG DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.3/Makefile b/linux/ecosystem/atlassian/confluence/7/7.20.3/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.3/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.3/docker-compose.yml b/linux/ecosystem/atlassian/confluence/7/7.20.3/docker-compose.yml new file mode 100644 index 000000000..1cb311828 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.3/docker-compose.yml @@ -0,0 +1,11 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:7.20.3" + build: + context: . + app-jdk11: + image: "epicmorg/confluence:7.20.3-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 diff --git a/linux/ecosystem/atlassian/confluence/7/7.20.3/entrypoint.sh b/linux/ecosystem/atlassian/confluence/7/7.20.3/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/7/7.20.3/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.0/.env b/linux/ecosystem/atlassian/confluence/8/8.0.0/.env new file mode 100644 index 000000000..804af17fe --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.0/.env @@ -0,0 +1,3 @@ + +RELEASE=8.0.0 +DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-8.0.0.tar.gz diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.0/Dockerfile b/linux/ecosystem/atlassian/confluence/8/8.0.0/Dockerfile new file mode 100644 index 000000000..1740f38c7 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.0/Dockerfile @@ -0,0 +1,45 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG RELEASE +ARG DOWNLOAD_URL + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.0/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/8/8.0.0/Dockerfile.jdk11 new file mode 100644 index 000000000..1a2cd4210 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.0/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG RELEASE +ARG DOWNLOAD_URL + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.0/Dockerfile.jdk17 b/linux/ecosystem/atlassian/confluence/8/8.0.0/Dockerfile.jdk17 new file mode 100644 index 000000000..f362b2321 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.0/Dockerfile.jdk17 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk17 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG RELEASE +ARG DOWNLOAD_URL + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.0/Makefile b/linux/ecosystem/atlassian/confluence/8/8.0.0/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.0/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.0/docker-compose.yml b/linux/ecosystem/atlassian/confluence/8/8.0.0/docker-compose.yml new file mode 100644 index 000000000..732168c9a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.0/docker-compose.yml @@ -0,0 +1,25 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:${RELEASE}" + build: + context: . + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} + app-jdk11: + image: "epicmorg/confluence:${RELEASE}-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} + app-jdk17: + image: "epicmorg/confluence:${RELEASE}-jdk17" + build: + context: . + dockerfile: Dockerfile.jdk17 + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.0/entrypoint.sh b/linux/ecosystem/atlassian/confluence/8/8.0.0/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.0/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.1/.env b/linux/ecosystem/atlassian/confluence/8/8.0.1/.env new file mode 100644 index 000000000..338cafa42 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.1/.env @@ -0,0 +1,3 @@ + +RELEASE=8.0.1 +DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-8.0.1.tar.gz diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.1/Dockerfile b/linux/ecosystem/atlassian/confluence/8/8.0.1/Dockerfile new file mode 100644 index 000000000..1740f38c7 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.1/Dockerfile @@ -0,0 +1,45 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG RELEASE +ARG DOWNLOAD_URL + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.1/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/8/8.0.1/Dockerfile.jdk11 new file mode 100644 index 000000000..1a2cd4210 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.1/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG RELEASE +ARG DOWNLOAD_URL + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.1/Dockerfile.jdk17 b/linux/ecosystem/atlassian/confluence/8/8.0.1/Dockerfile.jdk17 new file mode 100644 index 000000000..f362b2321 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.1/Dockerfile.jdk17 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk17 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG RELEASE +ARG DOWNLOAD_URL + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.1/Makefile b/linux/ecosystem/atlassian/confluence/8/8.0.1/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.1/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.1/docker-compose.yml b/linux/ecosystem/atlassian/confluence/8/8.0.1/docker-compose.yml new file mode 100644 index 000000000..732168c9a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.1/docker-compose.yml @@ -0,0 +1,25 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:${RELEASE}" + build: + context: . + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} + app-jdk11: + image: "epicmorg/confluence:${RELEASE}-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} + app-jdk17: + image: "epicmorg/confluence:${RELEASE}-jdk17" + build: + context: . + dockerfile: Dockerfile.jdk17 + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.1/entrypoint.sh b/linux/ecosystem/atlassian/confluence/8/8.0.1/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.1/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.2/.env b/linux/ecosystem/atlassian/confluence/8/8.0.2/.env new file mode 100644 index 000000000..168a590ac --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.2/.env @@ -0,0 +1,3 @@ + +RELEASE=8.0.2 +DOWNLOAD_URL=http://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-8.0.2.tar.gz diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.2/Dockerfile b/linux/ecosystem/atlassian/confluence/8/8.0.2/Dockerfile new file mode 100644 index 000000000..1740f38c7 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.2/Dockerfile @@ -0,0 +1,45 @@ +FROM epicmorg/debian:bullseye-jdk8 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG RELEASE +ARG DOWNLOAD_URL + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.2/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/8/8.0.2/Dockerfile.jdk11 new file mode 100644 index 000000000..1a2cd4210 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.2/Dockerfile.jdk11 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk11 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG RELEASE +ARG DOWNLOAD_URL + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.2/Dockerfile.jdk17 b/linux/ecosystem/atlassian/confluence/8/8.0.2/Dockerfile.jdk17 new file mode 100644 index 000000000..f362b2321 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.2/Dockerfile.jdk17 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk17 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG RELEASE +ARG DOWNLOAD_URL + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.2/Makefile b/linux/ecosystem/atlassian/confluence/8/8.0.2/Makefile new file mode 100644 index 000000000..9ef622aa9 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.2/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel --progress plain + +deploy: + docker-compose push + +clean: + docker container prune -f + docker image prune -f + docker network prune -f + docker volume prune -f + docker system prune -af diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.2/docker-compose.yml b/linux/ecosystem/atlassian/confluence/8/8.0.2/docker-compose.yml new file mode 100644 index 000000000..732168c9a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.2/docker-compose.yml @@ -0,0 +1,25 @@ +version: '3.9' +services: + app: + image: "epicmorg/confluence:${RELEASE}" + build: + context: . + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} + app-jdk11: + image: "epicmorg/confluence:${RELEASE}-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} + app-jdk17: + image: "epicmorg/confluence:${RELEASE}-jdk17" + build: + context: . + dockerfile: Dockerfile.jdk17 + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} diff --git a/linux/ecosystem/atlassian/confluence/8/8.0.2/entrypoint.sh b/linux/ecosystem/atlassian/confluence/8/8.0.2/entrypoint.sh new file mode 100755 index 000000000..250fc031a --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/8/8.0.2/entrypoint.sh @@ -0,0 +1,39 @@ +#!/bin/bash +set -euo pipefail + +export JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::") +export JRE_HOME="$JAVA_HOME/jre" +export JAVA_BINARY="$JRE_HOME/bin/java" +export JAVA_VERSION=$("$JAVA_BINARY" -version 2>&1 | awk -F '"' '/version/ {print $2}') + + +# Setup Catalina Opts +: ${CATALINA_CONNECTOR_PROXYNAME:=} +: ${CATALINA_CONNECTOR_PROXYPORT:=} +: ${CATALINA_CONNECTOR_SCHEME:=http} +: ${CATALINA_CONNECTOR_SECURE:=false} + +: ${CATALINA_OPTS:=} + +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyName=${CATALINA_CONNECTOR_PROXYNAME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorProxyPort=${CATALINA_CONNECTOR_PROXYPORT}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorScheme=${CATALINA_CONNECTOR_SCHEME}" +CATALINA_OPTS="${CATALINA_OPTS} -DcatalinaConnectorSecure=${CATALINA_CONNECTOR_SECURE}" + +export CATALINA_OPTS + + +# Start Confluence as the correct user +if [ "${UID}" -eq 0 ]; then + echo "User is currently root. Will change directory ownership to ${RUN_USER}:${RUN_GROUP}, then downgrade permission to ${RUN_USER}" + PERMISSIONS_SIGNATURE=$(stat -c "%u:%U:%a" "${CONFLUENCE_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${CONFLUENCE_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${CONFLUENCE_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh $@" +else + exec "$CONFLUENCE_INSTALL_DIR/bin/start-confluence.sh" "$@" +fi diff --git a/linux/ecosystem/atlassian/confluence/latest/Dockerfile.jdk17 b/linux/ecosystem/atlassian/confluence/latest/Dockerfile.jdk17 new file mode 100644 index 000000000..3ab236121 --- /dev/null +++ b/linux/ecosystem/atlassian/confluence/latest/Dockerfile.jdk17 @@ -0,0 +1,46 @@ +FROM epicmorg/debian:bullseye-jdk17 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ARG CONFLUENCE_VERSION=7.19.1 +ARG DOWNLOAD_URL=https://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/doc/confluence-home-and-other-important-directories-590259707.html +ENV CONFLUENCE_HOME /var/atlassian/application-data/confluence +ENV CONFLUENCE_INSTALL_DIR /opt/atlassian/confluence + +VOLUME ["${CONFLUENCE_HOME}"] +WORKDIR $CONFLUENCE_HOME + +# Expose HTTP and Synchrony ports +EXPOSE 8090 +EXPOSE 8091 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${CONFLUENCE_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$CONFLUENCE_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${CONFLUENCE_INSTALL_DIR}/ \ + && sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${CONFLUENCE_HOME}/g' ${CONFLUENCE_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/port="8090"/port="8090" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${CONFLUENCE_INSTALL_DIR}/conf/server.xml && \ + + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/confluence/latest/docker-compose.yml b/linux/ecosystem/atlassian/confluence/latest/docker-compose.yml index 191f5b119..66c8366b8 100644 --- a/linux/ecosystem/atlassian/confluence/latest/docker-compose.yml +++ b/linux/ecosystem/atlassian/confluence/latest/docker-compose.yml @@ -4,3 +4,13 @@ services: image: "epicmorg/confluence:latest" build: context: . + app-jdk11: + image: "epicmorg/confluence:latest-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 + app-jdk17: + image: "epicmorg/confluence:latest-jdk17" + build: + context: . + dockerfile: Dockerfile.jdk17 diff --git a/linux/ecosystem/atlassian/jira/latest/Dockerfile.jdk17 b/linux/ecosystem/atlassian/jira/latest/Dockerfile.jdk17 new file mode 100644 index 000000000..3e2130633 --- /dev/null +++ b/linux/ecosystem/atlassian/jira/latest/Dockerfile.jdk17 @@ -0,0 +1,49 @@ +FROM epicmorg/debian:bullseye-jdk17 +LABEL maintainer="Atlassian Jira Server Team; EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## + +#configured by dockerfile / .ENV +ARG RELEASE +ARG DOWNLOAD_URL + + +################################################################## +# Setup +################################################################## +ENV RUN_USER daemon +ENV RUN_GROUP daemon + +# https://confluence.atlassian.com/display/JSERVERM/Important+directories+and+files +ENV JIRA_HOME /var/atlassian/application-data/jira +ENV JIRA_INSTALL_DIR /opt/atlassian/jira + +VOLUME ["${JIRA_HOME}"] +WORKDIR $JIRA_HOME + +# Expose HTTP port +EXPOSE 8080 + +################################################################## +# Installing +################################################################## +RUN mkdir -p ${JIRA_INSTALL_DIR} \ + && curl -L ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$JIRA_INSTALL_DIR" \ + && chown -R ${RUN_USER}:${RUN_GROUP} ${JIRA_INSTALL_DIR}/ \ + && sed -i -e 's/^JVM_SUPPORT_RECOMMENDED_ARGS=""$/: \${JVM_SUPPORT_RECOMMENDED_ARGS:=""}/g' ${JIRA_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/^JVM_\(.*\)_MEMORY="\(.*\)"$/: \${JVM_\1_MEMORY:=\2}/g' ${JIRA_INSTALL_DIR}/bin/setenv.sh \ + && sed -i -e 's/grep "java version"/grep -E "(openjdk|java) version"/g' ${JIRA_INSTALL_DIR}/bin/check-java.sh \ + && sed -i -e 's/port="8080"/port="8080" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${JIRA_INSTALL_DIR}/conf/server.xml && \ + update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \ + apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb + +CMD ["/entrypoint.sh", "-fg"] +ENTRYPOINT ["/usr/bin/tini", "--"] +COPY entrypoint.sh /entrypoint.sh +COPY . /tmp diff --git a/linux/ecosystem/atlassian/jira/latest/docker-compose.yml b/linux/ecosystem/atlassian/jira/latest/docker-compose.yml index 89548e5ac..681e472c0 100644 --- a/linux/ecosystem/atlassian/jira/latest/docker-compose.yml +++ b/linux/ecosystem/atlassian/jira/latest/docker-compose.yml @@ -9,6 +9,14 @@ services: DOWNLOAD_URL: ${DOWNLOAD_URL} app-jdk11: image: "epicmorg/jira:latest-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} + app-jdk17: + image: "epicmorg/jira:latest-jdk17" build: context: . dockerfile: Dockerfile.jdk11