From 5ae0ce2484d05ddccfe0dc15f2d4d51647a0bae7 Mon Sep 17 00:00:00 2001 From: EpicMorg Date: Sat, 20 Nov 2021 02:58:05 +0300 Subject: [PATCH 01/20] vscode --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 90e2faf1b..8d2128e22 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ +# Temp make file for local builds and debug Makefile.temp From bd02798b531cdee0b50f040d36d9fc6df87eedcc Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Tue, 14 Dec 2021 12:51:45 +0300 Subject: [PATCH 02/20] 8.21.0 --- linux/ecosystem/atlassian/jira/8/8.21.0/.env | 3 + .../atlassian/jira/8/8.21.0/Dockerfile | 49 ++++++++++ .../atlassian/jira/8/8.21.0/Dockerfile.jdk11 | 49 ++++++++++ .../atlassian/jira/8/8.21.0/Makefile | 19 ++++ .../jira/8/8.21.0/docker-compose.yml | 17 ++++ .../atlassian/jira/8/8.21.0/entrypoint.sh | 89 +++++++++++++++++++ 6 files changed, 226 insertions(+) create mode 100644 linux/ecosystem/atlassian/jira/8/8.21.0/.env create mode 100644 linux/ecosystem/atlassian/jira/8/8.21.0/Dockerfile create mode 100644 linux/ecosystem/atlassian/jira/8/8.21.0/Dockerfile.jdk11 create mode 100644 linux/ecosystem/atlassian/jira/8/8.21.0/Makefile create mode 100644 linux/ecosystem/atlassian/jira/8/8.21.0/docker-compose.yml create mode 100755 linux/ecosystem/atlassian/jira/8/8.21.0/entrypoint.sh diff --git a/linux/ecosystem/atlassian/jira/8/8.21.0/.env b/linux/ecosystem/atlassian/jira/8/8.21.0/.env new file mode 100644 index 000000000..7a3eda920 --- /dev/null +++ b/linux/ecosystem/atlassian/jira/8/8.21.0/.env @@ -0,0 +1,3 @@ + +RELEASE=8.21.0 +DOWNLOAD_URL=https://www.atlassian.com/software/jira/downloads/binary/atlassian-jira-software-8.21.0.tar.gz diff --git a/linux/ecosystem/atlassian/jira/8/8.21.0/Dockerfile b/linux/ecosystem/atlassian/jira/8/8.21.0/Dockerfile new file mode 100644 index 000000000..eeec7c1d8 --- /dev/null +++ b/linux/ecosystem/atlassian/jira/8/8.21.0/Dockerfile @@ -0,0 +1,49 @@ +FROM epicmorg/prod:jdk8 +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/8/8.21.0/Dockerfile.jdk11 b/linux/ecosystem/atlassian/jira/8/8.21.0/Dockerfile.jdk11 new file mode 100644 index 000000000..a98a20e49 --- /dev/null +++ b/linux/ecosystem/atlassian/jira/8/8.21.0/Dockerfile.jdk11 @@ -0,0 +1,49 @@ +FROM epicmorg/prod:jdk11 +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/8/8.21.0/Makefile b/linux/ecosystem/atlassian/jira/8/8.21.0/Makefile new file mode 100644 index 000000000..bad6d73b5 --- /dev/null +++ b/linux/ecosystem/atlassian/jira/8/8.21.0/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel + +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/jira/8/8.21.0/docker-compose.yml b/linux/ecosystem/atlassian/jira/8/8.21.0/docker-compose.yml new file mode 100644 index 000000000..81592d775 --- /dev/null +++ b/linux/ecosystem/atlassian/jira/8/8.21.0/docker-compose.yml @@ -0,0 +1,17 @@ +version: '3.9' +services: + app: + image: "epicmorg/jira:${RELEASE}" + build: + context: . + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} + app-jdk11: + image: "epicmorg/jira:${RELEASE}-jdk11" + build: + context: . + dockerfile: Dockerfile.jdk11 + args: + RELEASE: ${RELEASE} + DOWNLOAD_URL: ${DOWNLOAD_URL} diff --git a/linux/ecosystem/atlassian/jira/8/8.21.0/entrypoint.sh b/linux/ecosystem/atlassian/jira/8/8.21.0/entrypoint.sh new file mode 100755 index 000000000..50ee4ecd1 --- /dev/null +++ b/linux/ecosystem/atlassian/jira/8/8.21.0/entrypoint.sh @@ -0,0 +1,89 @@ +#!/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:=} + +: ${JAVA_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 JAVA_OPTS="${JAVA_OPTS} ${CATALINA_OPTS}" + +# Setup Data Center configuration +if [ ! -f "/etc/container_id" ]; then + uuidgen > /etc/container_id +fi +CONTAINER_ID=$(cat /etc/container_id) +CONTAINER_SHORT_ID=${CONTAINER_ID::8} + +: ${CLUSTERED:=false} +: ${JIRA_NODE_ID:=jira_node_${CONTAINER_SHORT_ID}} +: ${JIRA_SHARED_HOME:=${JIRA_HOME}/shared} +: ${EHCACHE_PEER_DISCOVERY:=} +: ${EHCACHE_LISTENER_HOSTNAME:=} +: ${EHCACHE_LISTENER_PORT:=} +: ${EHCACHE_LISTENER_SOCKETTIMEOUTMILLIS:=} +: ${EHCACHE_MULTICAST_ADDRESS:=} +: ${EHCACHE_MULTICAST_PORT:=} +: ${EHCACHE_MULTICAST_TIMETOLIVE:=} +: ${EHCACHE_MULTICAST_HOSTNAME:=} + +# Cleanly set/unset values in cluster.properties +function set_cluster_property { + if [ -z $2 ]; then + if [ -f "${JIRA_HOME}/cluster.properties" ]; then + sed -i -e "/^${1}/d" "${JIRA_HOME}/cluster.properties" + fi + return + fi + if [ ! -f "${JIRA_HOME}/cluster.properties" ]; then + echo "${1}=${2}" >> "${JIRA_HOME}/cluster.properties" + elif grep "^${1}" "${JIRA_HOME}/cluster.properties"; then + sed -i -e "s#^${1}=.*#${1}=${2}#g" "${JIRA_HOME}/cluster.properties" + else + echo "${1}=${2}" >> "${JIRA_HOME}/cluster.properties" + fi +} + +if [ "${CLUSTERED}" == "true" ]; then + set_cluster_property "jira.node.id" "${JIRA_NODE_ID}" + set_cluster_property "jira.shared.home" "${JIRA_SHARED_HOME}" + set_cluster_property "ehcache.peer.discovery" "${EHCACHE_PEER_DISCOVERY}" + set_cluster_property "ehcache.listener.hostName" "${EHCACHE_LISTENER_HOSTNAME}" + set_cluster_property "ehcache.listener.port" "${EHCACHE_LISTENER_PORT}" + set_cluster_property "ehcache.listener.socketTimeoutMillis" "${EHCACHE_LISTENER_PORT}" + set_cluster_property "ehcache.multicast.address" "${EHCACHE_MULTICAST_ADDRESS}" + set_cluster_property "ehcache.multicast.port" "${EHCACHE_MULTICAST_PORT}" + set_cluster_property "ehcache.multicast.timeToLive" "${EHCACHE_MULTICAST_TIMETOLIVE}" + set_cluster_property "ehcache.multicast.hostName" "${EHCACHE_MULTICAST_HOSTNAME}" +fi + + +# Start Jira 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" "${JIRA_HOME}") + EXPECTED_PERMISSIONS=$(id -u ${RUN_USER}):${RUN_USER}:700 + if [ "${PERMISSIONS_SIGNATURE}" != "${EXPECTED_PERMISSIONS}" ]; then + chmod -R 700 "${JIRA_HOME}" && + chown -R "${RUN_USER}:${RUN_GROUP}" "${JIRA_HOME}" + fi + # Now drop privileges + exec su -s /bin/bash "${RUN_USER}" -c "$JIRA_INSTALL_DIR/bin/start-jira.sh $@" +else + exec "$JIRA_INSTALL_DIR/bin/start-jira.sh" "$@" +fi From 975fab581fc78e87f3e5fbe85912d5e976585aee Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Wed, 15 Dec 2021 15:58:21 +0300 Subject: [PATCH 03/20] 7.19.0 --- linux/ecosystem/atlassian/bitbucket/latest/Dockerfile | 2 +- linux/ecosystem/atlassian/bitbucket/latest/Dockerfile.jdk11 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile b/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile index abff7dcaa..31b687fdd 100644 --- a/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile +++ b/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile @@ -5,7 +5,7 @@ ARG DEBIAN_FRONTEND=noninteractive ################################################################## # ARGuments ################################################################## -ARG BITBUCKET_VERSION=7.11.2 +ARG BITBUCKET_VERSION=7.19.0 ARG DOWNLOAD_URL=https://product-downloads.atlassian.com/software/stash/downloads/atlassian-bitbucket-${BITBUCKET_VERSION}.tar.gz ################################################################## diff --git a/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile.jdk11 b/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile.jdk11 index c33b2a5bb..58c175d81 100644 --- a/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile.jdk11 +++ b/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile.jdk11 @@ -5,7 +5,7 @@ ARG DEBIAN_FRONTEND=noninteractive ################################################################## # ARGuments ################################################################## -ARG BITBUCKET_VERSION=7.11.2 +ARG BITBUCKET_VERSION=7.19.0 ARG DOWNLOAD_URL=https://product-downloads.atlassian.com/software/stash/downloads/atlassian-bitbucket-${BITBUCKET_VERSION}.tar.gz ################################################################## From f4980a71fceeeec654e45bf3e4fe7255d201b7c5 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Wed, 15 Dec 2021 19:01:31 +0300 Subject: [PATCH 04/20] updates --- CHANGELOG.md | 2 ++ .../atlassian/confluence/latest/Dockerfile | 2 +- .../confluence/latest/Dockerfile.jdk11 | 2 +- linux/ecosystem/atlassian/jira/latest/.env | 4 ++-- linux/ecosystem/epicmorg/prod/main/Dockerfile | 20 ++++++++++++++++++- linux/ecosystem/nginx/latest/main/.env | 2 +- linux/ecosystem/nginx/latest/php/.env | 2 +- linux/ecosystem/nginx/latest/rtmp-hls/.env | 2 +- 8 files changed, 28 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 90fb9761b..2c975b150 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,7 @@ ## Changelog ### 2021 +* `december` + * added `git-lfs`, `lazygit`, bumped versions of nginx, jira, conflunce and bitbucket. * `october-november` * added `nginx:quic` image. UNSTABLE. * added `redash:latest` image in to `advanced` pack. diff --git a/linux/ecosystem/atlassian/confluence/latest/Dockerfile b/linux/ecosystem/atlassian/confluence/latest/Dockerfile index a0bf14609..33bbca38a 100644 --- a/linux/ecosystem/atlassian/confluence/latest/Dockerfile +++ b/linux/ecosystem/atlassian/confluence/latest/Dockerfile @@ -5,7 +5,7 @@ ARG DEBIAN_FRONTEND=noninteractive ################################################################## # ARGuments ################################################################## -ARG CONFLUENCE_VERSION=7.13.1 +ARG CONFLUENCE_VERSION=7.15.0 ARG DOWNLOAD_URL=https://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz ################################################################## diff --git a/linux/ecosystem/atlassian/confluence/latest/Dockerfile.jdk11 b/linux/ecosystem/atlassian/confluence/latest/Dockerfile.jdk11 index cd8c3c562..eb52ba98a 100644 --- a/linux/ecosystem/atlassian/confluence/latest/Dockerfile.jdk11 +++ b/linux/ecosystem/atlassian/confluence/latest/Dockerfile.jdk11 @@ -5,7 +5,7 @@ ARG DEBIAN_FRONTEND=noninteractive ################################################################## # ARGuments ################################################################## -ARG CONFLUENCE_VERSION=7.13.1 +ARG CONFLUENCE_VERSION=7.15.0 ARG DOWNLOAD_URL=https://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-${CONFLUENCE_VERSION}.tar.gz ################################################################## diff --git a/linux/ecosystem/atlassian/jira/latest/.env b/linux/ecosystem/atlassian/jira/latest/.env index 0aaefcf4d..7a3eda920 100644 --- a/linux/ecosystem/atlassian/jira/latest/.env +++ b/linux/ecosystem/atlassian/jira/latest/.env @@ -1,3 +1,3 @@ -RELEASE=8.17.1 -DOWNLOAD_URL=https://www.atlassian.com/software/jira/downloads/binary/atlassian-jira-software-8.17.1.tar.gz +RELEASE=8.21.0 +DOWNLOAD_URL=https://www.atlassian.com/software/jira/downloads/binary/atlassian-jira-software-8.21.0.tar.gz diff --git a/linux/ecosystem/epicmorg/prod/main/Dockerfile b/linux/ecosystem/epicmorg/prod/main/Dockerfile index e849863c1..732091b22 100644 --- a/linux/ecosystem/epicmorg/prod/main/Dockerfile +++ b/linux/ecosystem/epicmorg/prod/main/Dockerfile @@ -24,6 +24,12 @@ ENV P4_DOWNLOAD_URL=https://www.perforce.com/downloads/perforce/${P4_VERSION}/bi ENV SZ_VERSION=7z2103 ENV SZ_DOWNLOAD_URL=https://www.7-zip.org/a/${SZ_VERSION}-linux-x64.tar.xz +################################################################## +# LazyGit official binary +################################################################## +ENV LZGIT_VERSION=0.31.4 +ENV LZGIT_DOWNLOAD_URL=https://github.com/jesseduffield/lazygit/releases/download/v${LZGIT_VERSION}/lazygit_${LZGIT_VERSION}_Linux_x86_64.tar.gz + ################################################################## # installing utils ################################################################## @@ -47,6 +53,7 @@ RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selectio ffmpeg \ fontconfig \ git \ + git-lfs \ gnupg \ gnupg2 \ graphicsmagick \ @@ -115,6 +122,16 @@ RUN wget -nv --random-wait -c -O /tmp/7z.tar.xz ${SZ_DOWNLOAD_URL} && \ 7zz | head -4 && \ 7z | head -4 +################################################################## +# Install LazyGit official binary +################################################################## +RUN wget -nv --random-wait -c -O /tmp/lazygit.tar.xz ${LZGIT_DOWNLOAD_URL} && \ + mkdir -p /tmp/lazygit && \ + tar -zxvf /tmp/lazygit.tar.xz -C /tmp/lazygit && \ + chmod +x /tmp/lazygit/lazygit && \ + mv -fv /tmp/lazygit/lazygit /usr/bin/ && \ + lazygit --version + ################################################################## # Generate ssl key ################################################################## @@ -129,4 +146,5 @@ RUN apt purge policykit-1 -y && \ rm -rfv /var/lib/apt/lists/* && \ rm -rfv /tmp/mc.patch && \ rm -rfv /var/cache/apt/archives/*.deb && \ - rm -rfv /tmp/7z + rm -rfv /tmp/7z && \ + rm -rfv /tmp/lazygit diff --git a/linux/ecosystem/nginx/latest/main/.env b/linux/ecosystem/nginx/latest/main/.env index 00230635f..7de73fe60 100644 --- a/linux/ecosystem/nginx/latest/main/.env +++ b/linux/ecosystem/nginx/latest/main/.env @@ -1,2 +1,2 @@ NGINX_VERSION=latest -NGINX_DOWNLOAD_URL=http://nginx.org/download/nginx-1.21.3.tar.gz +NGINX_DOWNLOAD_URL=http://nginx.org/download/nginx-1.21.4.tar.gz diff --git a/linux/ecosystem/nginx/latest/php/.env b/linux/ecosystem/nginx/latest/php/.env index 00230635f..7de73fe60 100644 --- a/linux/ecosystem/nginx/latest/php/.env +++ b/linux/ecosystem/nginx/latest/php/.env @@ -1,2 +1,2 @@ NGINX_VERSION=latest -NGINX_DOWNLOAD_URL=http://nginx.org/download/nginx-1.21.3.tar.gz +NGINX_DOWNLOAD_URL=http://nginx.org/download/nginx-1.21.4.tar.gz diff --git a/linux/ecosystem/nginx/latest/rtmp-hls/.env b/linux/ecosystem/nginx/latest/rtmp-hls/.env index 00230635f..7de73fe60 100644 --- a/linux/ecosystem/nginx/latest/rtmp-hls/.env +++ b/linux/ecosystem/nginx/latest/rtmp-hls/.env @@ -1,2 +1,2 @@ NGINX_VERSION=latest -NGINX_DOWNLOAD_URL=http://nginx.org/download/nginx-1.21.3.tar.gz +NGINX_DOWNLOAD_URL=http://nginx.org/download/nginx-1.21.4.tar.gz From 5c10e7aed46c2c0bc1a2cb2a984e6c5c5406380c Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Thu, 16 Dec 2021 00:53:51 +0300 Subject: [PATCH 05/20] updates --- linux/ecosystem/epicmorg/edge/main/Dockerfile | 7 +++++++ linux/ecosystem/epicmorg/prod/main/Dockerfile | 14 +++++++++++++- .../epicmorg/prod/main/github_git-lfs.list | 2 ++ 3 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 linux/ecosystem/epicmorg/prod/main/github_git-lfs.list diff --git a/linux/ecosystem/epicmorg/edge/main/Dockerfile b/linux/ecosystem/epicmorg/edge/main/Dockerfile index 6c340284e..5a0035a03 100644 --- a/linux/ecosystem/epicmorg/edge/main/Dockerfile +++ b/linux/ecosystem/epicmorg/edge/main/Dockerfile @@ -2,6 +2,13 @@ FROM epicmorg/prod LABEL maintainer="EpicMorg DevTeam, developer@epicm.org" ARG DEBIAN_FRONTEND=noninteractive +################################################################## +# git-lfs official binary +################################################################## +RUN curl -L https://packagecloud.io/github/git-lfs/gpgkey | apt-key add - && \ + rm -rfv /etc/apt/sources.list.d/github_git-lfs.list +COPY github_git-lfs.list /etc/apt/sources.list.d/github_git-lfs.list + ################################################################## # bullseye sources list ################################################################## diff --git a/linux/ecosystem/epicmorg/prod/main/Dockerfile b/linux/ecosystem/epicmorg/prod/main/Dockerfile index 732091b22..8407863b1 100644 --- a/linux/ecosystem/epicmorg/prod/main/Dockerfile +++ b/linux/ecosystem/epicmorg/prod/main/Dockerfile @@ -15,7 +15,7 @@ RUN for i in $(seq 1 8); do mkdir -p "/usr/share/man/man${i}"; done ################################################################## # perforce client binary ################################################################## -ENV P4_VERSION=r21.1 +ENV P4_VERSION=r21.2 ENV P4_DOWNLOAD_URL=https://www.perforce.com/downloads/perforce/${P4_VERSION}/bin.linux26x86_64/p4 ################################################################## @@ -30,6 +30,7 @@ ENV SZ_DOWNLOAD_URL=https://www.7-zip.org/a/${SZ_VERSION}-linux-x64.tar.xz ENV LZGIT_VERSION=0.31.4 ENV LZGIT_DOWNLOAD_URL=https://github.com/jesseduffield/lazygit/releases/download/v${LZGIT_VERSION}/lazygit_${LZGIT_VERSION}_Linux_x86_64.tar.gz + ################################################################## # installing utils ################################################################## @@ -105,6 +106,17 @@ RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selectio wget \ zip +################################################################## +# git-lfs official binary +################################################################## +RUN curl -L https://packagecloud.io/github/git-lfs/gpgkey | apt-key add - && \ + rm -rfv /etc/apt/sources.list.d/github_git-lfs.list +COPY github_git-lfs.list /etc/apt/sources.list.d/github_git-lfs.list +RUN apt-get update && \ + apt-get install -y --allow-unauthenticated \ + git \ + git-lfs + ################################################################## # Install p4client ################################################################## diff --git a/linux/ecosystem/epicmorg/prod/main/github_git-lfs.list b/linux/ecosystem/epicmorg/prod/main/github_git-lfs.list new file mode 100644 index 000000000..867534422 --- /dev/null +++ b/linux/ecosystem/epicmorg/prod/main/github_git-lfs.list @@ -0,0 +1,2 @@ +deb https://packagecloud.io/github/git-lfs/debian/ buster main +deb-src https://packagecloud.io/github/git-lfs/debian/ buster main From e705e1126eca66fbbf758684c8264c46f1cfcf47 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Thu, 16 Dec 2021 01:12:49 +0300 Subject: [PATCH 06/20] updates --- CHANGELOG.md | 2 ++ .../epicmorg/edge/main/github_git-lfs.list | 2 ++ linux/ecosystem/epicmorg/prod/main/Dockerfile | 28 ++++++++++++++++--- .../epicmorg/prod/main/github-cli.list | 1 + 4 files changed, 29 insertions(+), 4 deletions(-) create mode 100644 linux/ecosystem/epicmorg/edge/main/github_git-lfs.list create mode 100644 linux/ecosystem/epicmorg/prod/main/github-cli.list diff --git a/CHANGELOG.md b/CHANGELOG.md index 2c975b150..9663faedd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ ### 2021 * `december` * added `git-lfs`, `lazygit`, bumped versions of nginx, jira, conflunce and bitbucket. + * added another git addons + * added `gh` - `github-cli` support * `october-november` * added `nginx:quic` image. UNSTABLE. * added `redash:latest` image in to `advanced` pack. diff --git a/linux/ecosystem/epicmorg/edge/main/github_git-lfs.list b/linux/ecosystem/epicmorg/edge/main/github_git-lfs.list new file mode 100644 index 000000000..8cf93d426 --- /dev/null +++ b/linux/ecosystem/epicmorg/edge/main/github_git-lfs.list @@ -0,0 +1,2 @@ +deb https://packagecloud.io/github/git-lfs/debian/ bullseye main +deb-src https://packagecloud.io/github/git-lfs/debian/ bullseye main diff --git a/linux/ecosystem/epicmorg/prod/main/Dockerfile b/linux/ecosystem/epicmorg/prod/main/Dockerfile index 8407863b1..25945cac0 100644 --- a/linux/ecosystem/epicmorg/prod/main/Dockerfile +++ b/linux/ecosystem/epicmorg/prod/main/Dockerfile @@ -30,7 +30,6 @@ ENV SZ_DOWNLOAD_URL=https://www.7-zip.org/a/${SZ_VERSION}-linux-x64.tar.xz ENV LZGIT_VERSION=0.31.4 ENV LZGIT_DOWNLOAD_URL=https://github.com/jesseduffield/lazygit/releases/download/v${LZGIT_VERSION}/lazygit_${LZGIT_VERSION}_Linux_x86_64.tar.gz - ################################################################## # installing utils ################################################################## @@ -54,7 +53,16 @@ RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selectio ffmpeg \ fontconfig \ git \ + git-extras \ + git-flow \ + git-cvs \ + git-doc \ + git-email \ + git-mediawiki \ + git-crypt \ git-lfs \ + git-ftp \ + git-hub \ gnupg \ gnupg2 \ graphicsmagick \ @@ -107,15 +115,27 @@ RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selectio zip ################################################################## -# git-lfs official binary +# gh official binary ################################################################## -RUN curl -L https://packagecloud.io/github/git-lfs/gpgkey | apt-key add - && \ +RUN curl -L https://cli.github.com/packages/githubcli-archive-keyring.gpg | apt-key add - && \ rm -rfv /etc/apt/sources.list.d/github_git-lfs.list COPY github_git-lfs.list /etc/apt/sources.list.d/github_git-lfs.list RUN apt-get update && \ apt-get install -y --allow-unauthenticated \ git \ - git-lfs + git-lfs && \ + git --version && \ + git-lfs --version + +################################################################## +# git-lfs official binary +################################################################## +RUN curl -L https://packagecloud.io/github/git-lfs/gpgkey | apt-key add - +COPY github-cli.list /etc/apt/sources.list.d/github-cli.list +RUN apt-get update && \ + apt-get install -y --allow-unauthenticated \ + gh && \ + gh --version ################################################################## # Install p4client diff --git a/linux/ecosystem/epicmorg/prod/main/github-cli.list b/linux/ecosystem/epicmorg/prod/main/github-cli.list new file mode 100644 index 000000000..4442663ff --- /dev/null +++ b/linux/ecosystem/epicmorg/prod/main/github-cli.list @@ -0,0 +1 @@ +deb https://cli.github.com/packages stable main From 1b231a9464cdb8750e7e924f8da98535e2f4a9eb Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Thu, 16 Dec 2021 01:44:29 +0300 Subject: [PATCH 07/20] updates --- linux/ecosystem/epicmorg/edge/main/Dockerfile | 7 +++-- .../{ => sources.list.d}/github_git-lfs.list | 0 .../main/{ => sources.list.d}/sources.list | 0 linux/ecosystem/epicmorg/prod/main/Dockerfile | 24 +++++++++++------- .../epicmorg/prod/main/{ => etc}/locale.gen | 0 .../prod/main/{ => etc}/locale.gen.full | 0 .../main/{ => sources.list.d}/github-cli.list | 0 .../{ => sources.list.d}/github_git-lfs.list | 0 .../main/{ => sources.list.d}/sources.list | 0 .../deb-multimedia-keyring.gpg | Bin .../githubcli-archive-keyring.gpg | Bin 0 -> 1795 bytes 11 files changed, 18 insertions(+), 13 deletions(-) rename linux/ecosystem/epicmorg/edge/main/{ => sources.list.d}/github_git-lfs.list (100%) rename linux/ecosystem/epicmorg/edge/main/{ => sources.list.d}/sources.list (100%) rename linux/ecosystem/epicmorg/prod/main/{ => etc}/locale.gen (100%) rename linux/ecosystem/epicmorg/prod/main/{ => etc}/locale.gen.full (100%) rename linux/ecosystem/epicmorg/prod/main/{ => sources.list.d}/github-cli.list (100%) rename linux/ecosystem/epicmorg/prod/main/{ => sources.list.d}/github_git-lfs.list (100%) rename linux/ecosystem/epicmorg/prod/main/{ => sources.list.d}/sources.list (100%) rename linux/ecosystem/epicmorg/prod/main/{ => trusted.gpg.d}/deb-multimedia-keyring.gpg (100%) create mode 100644 linux/ecosystem/epicmorg/prod/main/trusted.gpg.d/githubcli-archive-keyring.gpg diff --git a/linux/ecosystem/epicmorg/edge/main/Dockerfile b/linux/ecosystem/epicmorg/edge/main/Dockerfile index 5a0035a03..16b397180 100644 --- a/linux/ecosystem/epicmorg/edge/main/Dockerfile +++ b/linux/ecosystem/epicmorg/edge/main/Dockerfile @@ -5,15 +5,14 @@ ARG DEBIAN_FRONTEND=noninteractive ################################################################## # git-lfs official binary ################################################################## -RUN curl -L https://packagecloud.io/github/git-lfs/gpgkey | apt-key add - && \ - rm -rfv /etc/apt/sources.list.d/github_git-lfs.list -COPY github_git-lfs.list /etc/apt/sources.list.d/github_git-lfs.list +RUN rm -rfv /etc/apt/sources.list.d/github_git-lfs.list +COPY sources.list.d/github_git-lfs.list /etc/apt/sources.list.d/github_git-lfs.list ################################################################## # bullseye sources list ################################################################## RUN rm -rfv /etc/apt/sources.list -COPY sources.list /etc/apt/sources.list +COPY sources.list.d/sources.list /etc/apt/sources.list RUN apt update && \ apt autoremove -y && \ apt-get install -y libc6 libxml2-utils && \ diff --git a/linux/ecosystem/epicmorg/edge/main/github_git-lfs.list b/linux/ecosystem/epicmorg/edge/main/sources.list.d/github_git-lfs.list similarity index 100% rename from linux/ecosystem/epicmorg/edge/main/github_git-lfs.list rename to linux/ecosystem/epicmorg/edge/main/sources.list.d/github_git-lfs.list diff --git a/linux/ecosystem/epicmorg/edge/main/sources.list b/linux/ecosystem/epicmorg/edge/main/sources.list.d/sources.list similarity index 100% rename from linux/ecosystem/epicmorg/edge/main/sources.list rename to linux/ecosystem/epicmorg/edge/main/sources.list.d/sources.list diff --git a/linux/ecosystem/epicmorg/prod/main/Dockerfile b/linux/ecosystem/epicmorg/prod/main/Dockerfile index 25945cac0..c60d6adee 100644 --- a/linux/ecosystem/epicmorg/prod/main/Dockerfile +++ b/linux/ecosystem/epicmorg/prod/main/Dockerfile @@ -5,11 +5,16 @@ ARG DEBIAN_FRONTEND=noninteractive ################################################################## # buster sources list ################################################################## -COPY deb-multimedia-keyring.gpg /etc/apt/trusted.gpg.d/deb-multimedia-keyring.gpg +COPY trusted.gpg.d/deb-multimedia-keyring.gpg /etc/apt/trusted.gpg.d/deb-multimedia-keyring.gpg +COPY trusted.gpg.d/githubcli-archive-keyring.gpg /etc/apt/trusted.gpg.d/githubcli-archive-keyring.gpg + RUN rm /etc/apt/sources.list -COPY sources.list /etc/apt/sources.list +COPY sources.list.d/sources.list /etc/apt/sources.list + RUN apt update && apt dist-upgrade -y -COPY locale.gen /etc/locale.gen + +COPY etc/locale.gen /etc/locale.gen + RUN for i in $(seq 1 8); do mkdir -p "/usr/share/man/man${i}"; done ################################################################## @@ -115,11 +120,12 @@ RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selectio zip ################################################################## -# gh official binary +# git-lfs official binary ################################################################## -RUN curl -L https://cli.github.com/packages/githubcli-archive-keyring.gpg | apt-key add - && \ +#RUN curl -s https://packagecloud.io/github/git-lfs/gpgkey | sudo gpg --no-default-keyring --keyring gnupg-ring:/etc/apt/trusted.gpg.d/git-lfs.gpg --import && \ +RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 6B05F25D762E3157 && \ rm -rfv /etc/apt/sources.list.d/github_git-lfs.list -COPY github_git-lfs.list /etc/apt/sources.list.d/github_git-lfs.list +COPY sources.list.d/github_git-lfs.list /etc/apt/sources.list.d/github_git-lfs.list RUN apt-get update && \ apt-get install -y --allow-unauthenticated \ git \ @@ -128,10 +134,9 @@ RUN apt-get update && \ git-lfs --version ################################################################## -# git-lfs official binary +# gh official binary ################################################################## -RUN curl -L https://packagecloud.io/github/git-lfs/gpgkey | apt-key add - -COPY github-cli.list /etc/apt/sources.list.d/github-cli.list +COPY sources.list.d/github-cli.list /etc/apt/sources.list.d/github-cli.list RUN apt-get update && \ apt-get install -y --allow-unauthenticated \ gh && \ @@ -162,6 +167,7 @@ RUN wget -nv --random-wait -c -O /tmp/lazygit.tar.xz ${LZGIT_DOWNLOAD_URL} && \ tar -zxvf /tmp/lazygit.tar.xz -C /tmp/lazygit && \ chmod +x /tmp/lazygit/lazygit && \ mv -fv /tmp/lazygit/lazygit /usr/bin/ && \ + echo "lazygit version:" && \ lazygit --version ################################################################## diff --git a/linux/ecosystem/epicmorg/prod/main/locale.gen b/linux/ecosystem/epicmorg/prod/main/etc/locale.gen similarity index 100% rename from linux/ecosystem/epicmorg/prod/main/locale.gen rename to linux/ecosystem/epicmorg/prod/main/etc/locale.gen diff --git a/linux/ecosystem/epicmorg/prod/main/locale.gen.full b/linux/ecosystem/epicmorg/prod/main/etc/locale.gen.full similarity index 100% rename from linux/ecosystem/epicmorg/prod/main/locale.gen.full rename to linux/ecosystem/epicmorg/prod/main/etc/locale.gen.full diff --git a/linux/ecosystem/epicmorg/prod/main/github-cli.list b/linux/ecosystem/epicmorg/prod/main/sources.list.d/github-cli.list similarity index 100% rename from linux/ecosystem/epicmorg/prod/main/github-cli.list rename to linux/ecosystem/epicmorg/prod/main/sources.list.d/github-cli.list diff --git a/linux/ecosystem/epicmorg/prod/main/github_git-lfs.list b/linux/ecosystem/epicmorg/prod/main/sources.list.d/github_git-lfs.list similarity index 100% rename from linux/ecosystem/epicmorg/prod/main/github_git-lfs.list rename to linux/ecosystem/epicmorg/prod/main/sources.list.d/github_git-lfs.list diff --git a/linux/ecosystem/epicmorg/prod/main/sources.list b/linux/ecosystem/epicmorg/prod/main/sources.list.d/sources.list similarity index 100% rename from linux/ecosystem/epicmorg/prod/main/sources.list rename to linux/ecosystem/epicmorg/prod/main/sources.list.d/sources.list diff --git a/linux/ecosystem/epicmorg/prod/main/deb-multimedia-keyring.gpg b/linux/ecosystem/epicmorg/prod/main/trusted.gpg.d/deb-multimedia-keyring.gpg similarity index 100% rename from linux/ecosystem/epicmorg/prod/main/deb-multimedia-keyring.gpg rename to linux/ecosystem/epicmorg/prod/main/trusted.gpg.d/deb-multimedia-keyring.gpg diff --git a/linux/ecosystem/epicmorg/prod/main/trusted.gpg.d/githubcli-archive-keyring.gpg b/linux/ecosystem/epicmorg/prod/main/trusted.gpg.d/githubcli-archive-keyring.gpg new file mode 100644 index 0000000000000000000000000000000000000000..ce02b812e5c2df973f8d4a7372cf4f7dac2d3d81 GIT binary patch literal 1795 zcmajeX*e4Q8VB$s1c`)(Zi=W-)2JiPwjv0LyN-&WI;!p?#I=G>Rf3|9I_7bWsH3z7 zqlOZ7rOv9fvQ?$D>Pk_=#936awmY-)?0(z#+xtBK|EKr;6$7(`Juma3fiS>F=0B+g z#hV3_n(<*^16_mv)cl#~TF&L2+JQsNKXAkjoTqbl8Ep_>IM|UGh6$dOe zs8X8C6f>(B@joB@wYMxp&%nB$+UVc9-+d12e`#Qrg#R={cq!Xe5Py+bCM8KsjQ;Od*#=@cD%yz zy<3A&?X$TH)|2DKKmQ0EoPHs@i}cw#_2t=xm}rT;qP=+D$k52)Na}65OQ9~72f1V$ zQ~kiwEzXC&)vFR)-9~;EiW%8p|)+T3D+3t?*?6?Y( z&9SZFA6|Vd@_UJny3D67i|Ul$lp&Fz@>TZ2lvo&SOv_vYur2Wp@N3bNGtqiX&jj3S ztb2#XqlDG8{ zMf+&_hKCaV69@enPX~?(O9P<*0#Zp>qe{_Lph#;&o7cSHmLO)@qlp_}(7#U&LJ5H( zLVbY%usB3a6eRLDC`3#gB#ZQMe)M%*xMEnYu`DEYU zIJrHenavHkE>k^#%p&YKUhH%5Xhb?1aiyD?DOt(uS)e^29K;MIG>)6?9!rDB z0k_L(gS* z1$(RxJN-opM5h60BRF9rIgjNUjEjgX8+ z5rELQp8&M~*D5ZxC?`CZ=3l50kPQ3JRQbY_-TDEuJFn2dVN!*X}u!d-+kx&{<4 zRu?l=KO1Lj3=+zx1DuM??nilqU&7zbs{X-;tQR@Ggu3DgtsN;g$Ur*uC8XL@ID+}( zv*$P+^8IL(%^4Tgq+Uf6tRd+U!*Gb-X#|lnLJOD_$e$p#c^=!bm=wYllqT5zPNSormx@KK=EZ_^gZ2CoQ{Vd&sPMz zs%66l-1>wLd4Z!Jx#p$lwe#t)iOA%0E9^Q$;a;f;7*c9>U=;rh7d0fc|F*9o1sz79 z%*GcmPF7|e|D6z|cK;@)13}}@IhbymVUXfUh`vMHNQp_ciw6XI$KVgV<8*gs%W_b2g3a*&HD4 z#OI@bl%D44^0b1Ci%H{^d6CkEz-atgoo9J}SWO3Z3Cn!rhWS6-V1IJ^Usjig#g84X z>O>@oZW|b_f(Z(iX@1ZX8}io=+;wE1#%31%)O1+9O{}$W8%8kaB_7O z43n{Et;=6`eI??HLleB7R7ZYRyZ|xd?f|V$ciFXnaXlt_q)Nym)$s{h6!o6RS@QYj z;6Z=|av(rJ_SoKXV7RU|A4yw*^fkqeFk^0~mMs%V(>IcH%xal3#$-ZN-Mr0(Fd}!o z>o$T#^r3|GrG4;LNme3#!vjU zzhngXYGSS*jo0MWduji!Eh0B*!U;Bz2c;}6-*@?HtLmp4`({dxS#u{L{f$#bD(Kyo zYP*0sH_Di|%+$P*3v#+;_g?0HdA^@6nvDd-d*+XO2Go|g297Co9ILKimLaYcr1Tu) zqap~epiuf3s&}e*Yq?vBinIx>K~lnMRIfgHkgXJF-P?OK5|i95IHg2uJ*n%+&O1x@ Vq3;xM{p)VR8fciw*Mont`WIgEFnRz0 literal 0 HcmV?d00001 From fda11ce9c19084adbde619151e34331703e879c5 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Thu, 16 Dec 2021 19:11:50 +0300 Subject: [PATCH 08/20] update --- linux/ecosystem/apache2/latest/run.sh | 2 ++ linux/ecosystem/apache2/php7.2/run.sh | 2 ++ linux/ecosystem/apache2/php7.3/run.sh | 2 ++ linux/ecosystem/apache2/php7.4/run.sh | 2 ++ 4 files changed, 8 insertions(+) diff --git a/linux/ecosystem/apache2/latest/run.sh b/linux/ecosystem/apache2/latest/run.sh index e67d69a29..6bc50582d 100755 --- a/linux/ecosystem/apache2/latest/run.sh +++ b/linux/ecosystem/apache2/latest/run.sh @@ -1,5 +1,7 @@ #!/bin/bash +echo "Changing permissions for /var/www path. Dont worry, please wait." chown www-data:www-data /var/www -R +echo "Done. Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & exec apache2 -D FOREGROUND diff --git a/linux/ecosystem/apache2/php7.2/run.sh b/linux/ecosystem/apache2/php7.2/run.sh index e67d69a29..6bc50582d 100755 --- a/linux/ecosystem/apache2/php7.2/run.sh +++ b/linux/ecosystem/apache2/php7.2/run.sh @@ -1,5 +1,7 @@ #!/bin/bash +echo "Changing permissions for /var/www path. Dont worry, please wait." chown www-data:www-data /var/www -R +echo "Done. Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & exec apache2 -D FOREGROUND diff --git a/linux/ecosystem/apache2/php7.3/run.sh b/linux/ecosystem/apache2/php7.3/run.sh index e67d69a29..6bc50582d 100755 --- a/linux/ecosystem/apache2/php7.3/run.sh +++ b/linux/ecosystem/apache2/php7.3/run.sh @@ -1,5 +1,7 @@ #!/bin/bash +echo "Changing permissions for /var/www path. Dont worry, please wait." chown www-data:www-data /var/www -R +echo "Done. Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & exec apache2 -D FOREGROUND diff --git a/linux/ecosystem/apache2/php7.4/run.sh b/linux/ecosystem/apache2/php7.4/run.sh index e67d69a29..6bc50582d 100755 --- a/linux/ecosystem/apache2/php7.4/run.sh +++ b/linux/ecosystem/apache2/php7.4/run.sh @@ -1,5 +1,7 @@ #!/bin/bash +echo "Changing permissions for /var/www path. Dont worry, please wait." chown www-data:www-data /var/www -R +echo "Done. Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & exec apache2 -D FOREGROUND From 1cd8edebf096e093f1ce7f43fb8bbdaa9c91dae2 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Fri, 17 Dec 2021 03:48:02 +0300 Subject: [PATCH 09/20] updates --- linux/ecosystem/nginx/latest/main/Dockerfile | 4 +- .../teamcity/agent/android-sdk/Dockerfile | 2 +- .../teamcity/agent/dotnet-sdk/Dockerfile | 51 +++++++++++++++---- .../dotnet-sdk/sources.list.d/sources.11.list | 21 ++++++++ 4 files changed, 65 insertions(+), 13 deletions(-) create mode 100644 linux/ecosystem/teamcity/agent/dotnet-sdk/sources.list.d/sources.11.list diff --git a/linux/ecosystem/nginx/latest/main/Dockerfile b/linux/ecosystem/nginx/latest/main/Dockerfile index 2c3d58167..040057cfc 100644 --- a/linux/ecosystem/nginx/latest/main/Dockerfile +++ b/linux/ecosystem/nginx/latest/main/Dockerfile @@ -87,7 +87,7 @@ RUN wget -qO - ${NGINX_DOWNLOAD_URL} | tar -zxv --strip-components=1 -C ${NGINX_ git clone https://github.com/masterzen/nginx-upload-progress-module.git http-uploadprogress && \ git clone https://github.com/yaoweibin/ngx_http_substitutions_filter_module http-subs-filter && \ git clone https://github.com/grahamedgecombe/nginx-ct.git ssl-ct && \ - git clone https://github.com/stnoonan/spnego-http-auth-nginx-module.git spnego-http-auth-nginx-module && \ +# git clone https://github.com/stnoonan/spnego-http-auth-nginx-module.git spnego-http-auth-nginx-module && \ git clone https://github.com/leev/ngx_http_geoip2_module http-geoip2 && \ git clone https://github.com/flavioribeiro/nginx-audio-track-for-hls-module.git nginx-audio-track-for-hls-module && \ git clone https://github.com/chrislim2888/ip2location-nginx.git ip2location-nginx && \ @@ -167,7 +167,7 @@ RUN cd ${NGINX_SRC_DIR} && \ --add-dynamic-module=http-subs-filter \ --add-dynamic-module=ssl-ct \ --add-dynamic-module=http-geoip2 \ - --add-dynamic-module=spnego-http-auth-nginx-module \ +# --add-dynamic-module=spnego-http-auth-nginx-module \ --add-dynamic-module=http-auth-ldap \ # --add-dynamic-module=nginx-audio-track-for-hls-module \ --add-dynamic-module=ip2location-nginx \ diff --git a/linux/ecosystem/teamcity/agent/android-sdk/Dockerfile b/linux/ecosystem/teamcity/agent/android-sdk/Dockerfile index f9c7f9e67..5391ccb0b 100644 --- a/linux/ecosystem/teamcity/agent/android-sdk/Dockerfile +++ b/linux/ecosystem/teamcity/agent/android-sdk/Dockerfile @@ -22,7 +22,7 @@ RUN echo "24333f8a63b6825ea9c5514f83c2829b004d1fee" > /usr/lib/android-sdk/licen ################################################################## # SDKMAN ################################################################## -RUN curl -s "https://get.sdkman.io" | bash +RUN curl -s "http://get.sdkman.io" | bash ################################################################## # Gradle diff --git a/linux/ecosystem/teamcity/agent/dotnet-sdk/Dockerfile b/linux/ecosystem/teamcity/agent/dotnet-sdk/Dockerfile index 91d2e5fa8..d8b140625 100644 --- a/linux/ecosystem/teamcity/agent/dotnet-sdk/Dockerfile +++ b/linux/ecosystem/teamcity/agent/dotnet-sdk/Dockerfile @@ -2,53 +2,65 @@ FROM epicmorg/teamcity-agent:latest LABEL maintainer="EpicMorg DevTeam, developer@epicm.org" ARG DEBIAN_FRONTEND=noninteractive +COPY sources.list.d/sources.11.list /etc/apt/sources.list.d/sources.11.list + ################################################################## # teamcity dotnet+powershell setup ################################################################## # Opt out of the telemetry feature ENV DOTNET_CLI_TELEMETRY_OPTOUT=true - # Disable first time experience ENV DOTNET_SKIP_FIRST_TIME_EXPERIENCE=true - # Configure Kestrel web server to bind to port 80 when present ENV ASPNETCORE_URLS=\ - # Enable detection of running in a container ENV DOTNET_RUNNING_IN_CONTAINER=true - # Enable correct mode for dotnet watch (only mode supported in a container) ENV DOTNET_USE_POLLING_FILE_WATCHER=true - # Skip extraction of XML docs - generally not useful within an image/container - helps perfomance ENV NUGET_XMLDOC_MODE=skip - #unofficial support of openssl1.1 instead of 1.0 [https://stackoverflow.com/questions/51901359] ENV CLR_OPENSSL_VERSION_OVERRIDE=45 - # PowerShell telemetry for docker image usage ENV POWERSHELL_DISTRIBUTION_CHANNEL=PSDocker-DotnetSDK-Debian-10 - #Install packages RUN curl https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add - && \ - echo 'deb [arch=amd64,arm64,armhf] https://packages.microsoft.com/debian/10/prod buster main' > /etc/apt/sources.list.d/microsoft.dotnet.list && \ + echo 'deb [arch=amd64,arm64,armhf] https://packages.microsoft.com/debian/11/prod bullseye main' > /etc/apt/sources.list.d/microsoft.dotnet.list && \ apt-get update && \ apt-get install -y --no-install-recommends --allow-unauthenticated \ libc6 \ -# libgcc1 \ + libgcc1 \ libgssapi-krb5-2 \ libicu63 \ liblttng-ust0 \ libssl1.1 \ libstdc++6 \ zlib1g \ + dotnet-sdk-2.1 \ + dotnet-runtime-deps-2.1 \ + dotnet-runtime-2.1 \ + dotnet-hostfxr-2.1 \ + dotnet-sdk-3.1 \ + dotnet-targeting-pack-3.1 \ + dotnet-runtime-deps-3.1 \ + dotnet-runtime-3.1 \ + dotnet-hostfxr-3.1 \ + dotnet-apphost-pack-3.1 \ dotnet-sdk-5.0 \ dotnet-targeting-pack-5.0 \ dotnet-runtime-deps-5.0 \ dotnet-runtime-5.0 \ dotnet-hostfxr-5.0 \ dotnet-apphost-pack-5.0 \ + dotnet-sdk-6.0 \ + dotnet-targeting-pack-6.0 \ + dotnet-runtime-deps-6.0 \ + dotnet-runtime-6.0 \ + dotnet-hostfxr-6.0 \ + dotnet-apphost-pack-6.0 \ dotnet-host \ + procdump \ +# procmon \ powershell-preview \ powershell @@ -57,6 +69,25 @@ RUN dotnet help && \ pwsh-preview -v && \ pwsh -v + +################################################################## +# Mono +################################################################## +#RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF && \ +# echo "deb https://download.mono-project.com/repo/debian stable-buster main" | sudo tee /etc/apt/sources.list.d/mono-official-stable.list && \ +# echo "deb https://download.mono-project.com/repo/debian nightly-buster main" | sudo tee /etc/apt/sources.list.d/mono-official-nightly.list && \ +# echo "deb https://download.mono-project.com/repo/debian preview-buster main" | sudo tee /etc/apt/sources.list.d/mono-official-preview.list && \ +# apt-get update && \ +# apt-get install -y --allow-unauthenticated \ +# mono-complete \ +# mono-llvm-support \ +# mono-devel \ +# mono-dbg \ +# referenceassemblies-pcl \ +# ca-certificates-mono +# mono-xsp4 + + ################################################################## # cleaninig up ################################################################## diff --git a/linux/ecosystem/teamcity/agent/dotnet-sdk/sources.list.d/sources.11.list b/linux/ecosystem/teamcity/agent/dotnet-sdk/sources.list.d/sources.11.list new file mode 100644 index 000000000..5a8c0081a --- /dev/null +++ b/linux/ecosystem/teamcity/agent/dotnet-sdk/sources.list.d/sources.11.list @@ -0,0 +1,21 @@ +#main +deb http://httpredir.debian.org/debian/ bullseye main contrib non-free +deb-src http://httpredir.debian.org/debian/ bullseye main contrib non-free +deb http://httpredir.debian.org/debian/ bullseye-updates main contrib non-free +deb-src http://httpredir.debian.org/debian/ bullseye-updates main contrib non-free +deb http://httpredir.debian.org/debian/ bullseye-backports main contrib non-free +deb-src http://httpredir.debian.org/debian/ bullseye-backports main contrib non-free +deb http://httpredir.debian.org/debian/ bullseye-proposed-updates main contrib non-free +deb-src http://httpredir.debian.org/debian/ bullseye-proposed-updates main contrib non-free + +#security +deb http://httpredir.debian.org/debian-security/ bullseye-security main contrib non-free +deb-src http://httpredir.debian.org/debian-security/ bullseye-security main contrib non-free +deb http://httpredir.debian.org/debian-security/ bullseye-security/updates main contrib non-free +deb-src http://httpredir.debian.org/debian-security/ bullseye-security/updates main contrib non-free + +##multimedia +# deb http://httpredir.debian.org/debian-multimedia/ bullseye main non-free +# deb-src http://httpredir.debian.org/debian-multimedia/ bullseye main non-free +# deb http://httpredir.debian.org/debian-multimedia/ bullseye-backports main +# deb-src http://httpredir.debian.org/debian-multimedia/ bullseye-backports main From 0c8412646cbebee8c3ca2dce5d24797b8d9947ec Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Wed, 22 Dec 2021 01:38:09 +0300 Subject: [PATCH 10/20] updates --- Makefile | 1 - linux/ecosystem/atlassian/bitbucket/latest/Dockerfile | 2 +- linux/ecosystem/atlassian/bitbucket/latest/Dockerfile.jdk11 | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 61a561e98..3e61fe6c9 100644 --- a/Makefile +++ b/Makefile @@ -166,7 +166,6 @@ ecosystem-images: cd `pwd`/linux/ecosystem/nginx/latest/main && pwd && make cd `pwd`/linux/ecosystem/nginx/latest/php && pwd && make cd `pwd`/linux/ecosystem/nginx/latest/rtmp-hls && pwd && make - cd `pwd`/linux/ecosystem/nginx/latest/quic && pwd && make cd `pwd`/linux/advanced/vscode-server/latest && pwd && make build && make deploy cd `pwd`/linux/advanced/vscode-server/devops && pwd && make build && make deploy diff --git a/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile b/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile index 31b687fdd..31e8e73b7 100644 --- a/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile +++ b/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile @@ -5,7 +5,7 @@ ARG DEBIAN_FRONTEND=noninteractive ################################################################## # ARGuments ################################################################## -ARG BITBUCKET_VERSION=7.19.0 +ARG BITBUCKET_VERSION=7.19.1 ARG DOWNLOAD_URL=https://product-downloads.atlassian.com/software/stash/downloads/atlassian-bitbucket-${BITBUCKET_VERSION}.tar.gz ################################################################## diff --git a/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile.jdk11 b/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile.jdk11 index 58c175d81..c7f9f411c 100644 --- a/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile.jdk11 +++ b/linux/ecosystem/atlassian/bitbucket/latest/Dockerfile.jdk11 @@ -5,7 +5,7 @@ ARG DEBIAN_FRONTEND=noninteractive ################################################################## # ARGuments ################################################################## -ARG BITBUCKET_VERSION=7.19.0 +ARG BITBUCKET_VERSION=7.19.1 ARG DOWNLOAD_URL=https://product-downloads.atlassian.com/software/stash/downloads/atlassian-bitbucket-${BITBUCKET_VERSION}.tar.gz ################################################################## From b9342f9a76bd19a14147a596786278d2d0934737 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Wed, 22 Dec 2021 18:04:44 +0300 Subject: [PATCH 11/20] php8x --- linux/ecosystem/php/php8.0/Dockerfile | 270 ++++++++++++++++++ linux/ecosystem/php/php8.0/Makefile | 19 ++ linux/ecosystem/php/php8.0/README.md | 0 linux/ecosystem/php/php8.0/docker-compose.yml | 6 + .../php/php8.1-p4-not-ready/Dockerfile | 270 ++++++++++++++++++ .../php/php8.1-p4-not-ready/Makefile | 19 ++ .../php/php8.1-p4-not-ready/README.md | 0 .../php8.1-p4-not-ready/docker-compose.yml | 6 + 8 files changed, 590 insertions(+) create mode 100644 linux/ecosystem/php/php8.0/Dockerfile create mode 100644 linux/ecosystem/php/php8.0/Makefile create mode 100644 linux/ecosystem/php/php8.0/README.md create mode 100644 linux/ecosystem/php/php8.0/docker-compose.yml create mode 100644 linux/ecosystem/php/php8.1-p4-not-ready/Dockerfile create mode 100644 linux/ecosystem/php/php8.1-p4-not-ready/Makefile create mode 100644 linux/ecosystem/php/php8.1-p4-not-ready/README.md create mode 100644 linux/ecosystem/php/php8.1-p4-not-ready/docker-compose.yml diff --git a/linux/ecosystem/php/php8.0/Dockerfile b/linux/ecosystem/php/php8.0/Dockerfile new file mode 100644 index 000000000..178949c90 --- /dev/null +++ b/linux/ecosystem/php/php8.0/Dockerfile @@ -0,0 +1,270 @@ +FROM epicmorg/devel AS builder +LABEL maintainer="EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ENV BuildDocker true + +ARG BUILDS_DIR=/builds +ARG SRC_DIR=${BUILDS_DIR}/src +ARG EXPORT_DIR=${BUILDS_DIR}/export +ARG P4API_DIR=${SRC_DIR}/p4api +ARG P4PHP_DIR=${SRC_DIR}/p4php +ARG MAKE_DIR=${SRC_DIR}/p4php-${PHP_VER} + +ARG P4API_VER=r21.1 +ARG P4API_URL=https://www.perforce.com/downloads/perforce/${P4API_VER}/bin.linux26x86_64/p4api.tgz + +ARG P4PHP_VER=r20.2 +ARG P4PHP_URL=https://www.perforce.com/downloads/perforce/${P4PHP_VER}/bin.tools/p4php.tgz + +ARG PHP_VER=8.0 +ARG PHP_MODULE_VER=20200930 +ARG PHP_MODULE_PATH=/usr/lib/php/${PHP_MODULE_VER} + +################################################################## +# Files and folders +################################################################## +RUN mkdir -p ${BUILDS_DIR} ${SRC_DIR} ${EXPORT_DIR} ${MAKE_DIR} ${P4API_DIR} ${P4PHP_DIR} + +################################################################## +# Installing PHP8 +################################################################## +RUN wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg && \ + sh -c 'echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list' + +#Install base packages +RUN apt-get update && \ + apt-get install -y --allow-unauthenticated \ + libmemcached-dev \ + smbclient libsmbclient libsmbclient-dev \ + php8.0 \ + php8.0-dev \ + php8.0-fpm \ + php8.0-cli \ + php8.0-cgi + +################################################################## +# preparing p4src +################################################################## +RUN wget -qO - ${P4API_URL} | tar -zxv --strip-components=1 -C ${P4API_DIR} && \ + wget -qO - ${P4API_URL} | tar -zxv --strip-components=1 -C ${MAKE_DIR} && \ + wget -qO - ${P4PHP_URL} | tar -zxv --strip-components=1 -C ${P4PHP_DIR} && \ + wget -qO - ${P4PHP_URL} | tar -zxv --strip-components=1 -C ${MAKE_DIR} && \ + cd ${P4API_DIR} && \ + ls -las && \ + cd ${P4PHP_DIR} && \ + ls -las && \ + cd ${MAKE_DIR} && \ + ls -las && \ + cd ${SRC_DIR} && \ + ls -las + +################################################################## +# compilling p4src +################################################################## +RUN cd ${MAKE_DIR} && \ + ls -las && \ + phpize && \ + ./configure --with-perforce=${P4API_DIR} && \ + make && \ + make test && \ + make install && \ + cp ${PHP_MODULE_PATH}/perforce.so ${EXPORT_DIR} + +################################################################## +# compilling smbclient +################################################################## +RUN pecl install smbclient && \ + cp ${PHP_MODULE_PATH}/smbclient.so ${EXPORT_DIR} + +################################################################## +################################################################## +################################################################## + +FROM epicmorg/edge +LABEL maintainer="EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +ARG PHP_MODULE_VER=20200930 +ARG PHP_MODULE_PATH=/usr/lib/php/${PHP_MODULE_VER} +ARG PHP_VER=8.0 +ARG PHP_DIR=/etc/php/${PHP_VER} +ARG P4_PHP_INI=${PHP_DIR}/mods-available/perfroce.ini +ARG SMB_PHP_INI=${PHP_DIR}/mods-available/smbclient.ini + +################################################################## +# Installing PHP7 +################################################################## +RUN wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg && \ + sh -c 'echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list' + +RUN apt-get update && \ + apt-get install -y --allow-unauthenticated \ + libmemcached-dev \ + php8.0 \ + php8.0-dev \ + php8.0-fpm \ + php8.0-cli \ + php8.0-cgi \ + php-pear \ + php8.0-gmp \ + php8.0-snmp \ + php8.0-ldap \ + php8.0-mail \ + php8.0-soap \ + php8.0-mysql \ + php8.0-memcached \ + php8.0-memcache \ + php8.0-igbinary \ + php8.0-interbase \ + php8.0-curl \ + php8.0-gd \ + php8.0-intl \ + php8.0-zip \ + php8.0-bcmath \ + php8.0-imap \ + php8.0-pspell \ + php8.0-sqlite3 \ + php8.0-pgsql \ + php8.0-tidy \ + php8.0-xmlrpc \ + php8.0-xml \ + php8.0-mbstring \ + php8.0-apcu \ + php8.0-common \ +# php8.0-json \ + php8.0-readline \ + php8.0-enchant \ + php8.0-ssh2 \ + php8.0-oauth \ + php8.0-gmagick \ + php8.0-gnupg \ + php8.0-redis \ + smbclient libsmbclient \ + php8.0-yaml \ +# php8.0-geoip \ + sendmail && \ + ln -sf /etc/ssl/dhparam.pem /etc/php/dhparam.pem && \ + update-alternatives --set php /usr/bin/php8.0 && \ + pecl channel-update pecl.php.net && \ + php -m && \ + php -v + +################################################################## +# Enabling extensions +################################################################## +RUN phpenmod \ + snmp \ + gmp \ + calendar \ + ldap \ + curl \ + exif \ + ftp \ + fileinfo \ + gd \ + geoip \ + gnupg \ + iconv \ + imap \ + json \ + mbstring \ + memcached \ + mysqli \ + mysqlnd \ + oauth \ + pdo_mysql \ + pdo_sqlite \ + phar \ + posix \ + readline \ + redis \ + simplexml \ + sockets \ + sqlite3 \ + ssh2 \ + tokenizer \ + xml \ + xmlreader \ + xmlrpc \ + xmlwriter \ + xsl \ + yaml && \ + php -m && \ + php -v + +################################################################## +# Installing imagic addon +################################################################## +RUN apt-get update && \ + apt-get install -y --allow-unauthenticated \ + libmagickwand-dev \ + imagemagick && \ + pecl install imagick && \ +# echo "extension = ${PHP_MODULE_PATH}/imagick.so" >> ${PHP_DIR}/apache2/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/imagick.so" >> ${PHP_DIR}/cgi/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/imagick.so" >> ${PHP_DIR}/cli/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/imagick.so" >> ${PHP_DIR}/fpm/php.ini && \ + php -m && \ + php -v + +################################################################## +# not supported with php8 +################################################################## +# Installing IOnCube addon +################################################################# +#ADD https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz /tmp/ioncube.tar.gz +#RUN tar -C /tmp -xvf /tmp/ioncube.tar.gz && \ +# cp /tmp/ioncube/ioncube_loader_lin_7.4.so ${PHP_MODULE_PATH} && \ +## echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PHP_DIR}/apache2/php.ini && \ +# echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PHP_DIR}/cgi/php.ini && \ +# echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PHP_DIR}/cli/php.ini && \ +# echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PHP_DIR}/fpm/php.ini && \ +# php -m && \ +# php -v + +################################################################## +# Installing P4 addon +################################################################## +COPY --from=builder /builds/export/perforce.so ${PHP_MODULE_PATH} +RUN echo "extension = ${PHP_MODULE_PATH}/perforce.so" > ${P4_PHP_INI} && \ + ln -sf ${P4_PHP_INI} ${PHP_DIR}/cgi/conf.d/perforce.ini && \ + ln -sf ${P4_PHP_INI} ${PHP_DIR}/cli/conf.d/perforce.ini && \ + ln -sf ${P4_PHP_INI} ${PHP_DIR}/fpm/conf.d/perforce.ini && \ + php -m && \ + php -v + +################################################################## +# Installing smbclient addon +################################################################## +COPY --from=builder /builds/export/smbclient.so ${PHP_MODULE_PATH} +RUN echo "extension = ${PHP_MODULE_PATH}/smbclient.so" > ${SMB_PHP_INI} && \ + ln -sf ${SMB_PHP_INI} ${PHP_DIR}/cgi/conf.d/smbclient.ini && \ + ln -sf ${SMB_PHP_INI} ${PHP_DIR}/cli/conf.d/smbclient.ini && \ + ln -sf ${SMB_PHP_INI} ${PHP_DIR}/fpm/conf.d/smbclient.ini && \ + php -m && \ + php -v + +################################################################## +# Installing Composer addon +################################################################## +RUN cd /tmp && \ + php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" && \ + php composer-setup.php --install-dir=/usr/local/bin --filename=composer && \ + rm /tmp/composer-setup.php + +################################################################## +# cleaninig up +################################################################## +RUN apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb && \ + rm -rfv /tmp/deb/* && \ + rm -rfv /tmp/ioncube/* && \ + rm -rfv /tmp/composer-setup.php && \ + rm -rfv /tmp/ioncube.tar.gz + diff --git a/linux/ecosystem/php/php8.0/Makefile b/linux/ecosystem/php/php8.0/Makefile new file mode 100644 index 000000000..bad6d73b5 --- /dev/null +++ b/linux/ecosystem/php/php8.0/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel + +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/php/php8.0/README.md b/linux/ecosystem/php/php8.0/README.md new file mode 100644 index 000000000..e69de29bb diff --git a/linux/ecosystem/php/php8.0/docker-compose.yml b/linux/ecosystem/php/php8.0/docker-compose.yml new file mode 100644 index 000000000..f2025ac26 --- /dev/null +++ b/linux/ecosystem/php/php8.0/docker-compose.yml @@ -0,0 +1,6 @@ +version: '3.9' +services: + app: + image: "epicmorg/php:php8.0" + build: + context: . diff --git a/linux/ecosystem/php/php8.1-p4-not-ready/Dockerfile b/linux/ecosystem/php/php8.1-p4-not-ready/Dockerfile new file mode 100644 index 000000000..8c72b3fa9 --- /dev/null +++ b/linux/ecosystem/php/php8.1-p4-not-ready/Dockerfile @@ -0,0 +1,270 @@ +FROM epicmorg/devel AS builder +LABEL maintainer="EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +################################################################## +# ARGuments +################################################################## +ENV BuildDocker true + + +ARG BUILDS_DIR=/builds +ARG SRC_DIR=${BUILDS_DIR}/src +ARG EXPORT_DIR=${BUILDS_DIR}/export +ARG P4API_DIR=${SRC_DIR}/p4api +ARG P4PHP_DIR=${SRC_DIR}/p4php +ARG PHP_VER=8.1 +ARG MAKE_DIR=${SRC_DIR}/p4php-${PHP_VER} +ARG P4API_VER=r21.1 +ARG P4API_URL=https://www.perforce.com/downloads/perforce/${P4API_VER}/bin.linux26x86_64/p4api.tgz + +ARG P4PHP_VER=r20.2 +ARG P4PHP_URL=https://www.perforce.com/downloads/perforce/${P4PHP_VER}/bin.tools/p4php.tgz + +ARG PHP_MODULE_VER=20210902 +ARG PHP_MODULE_PATH=/usr/lib/php/${PHP_MODULE_VER} + +################################################################## +# Files and folders +################################################################## +RUN mkdir -p ${BUILDS_DIR} ${SRC_DIR} ${EXPORT_DIR} ${MAKE_DIR} ${P4API_DIR} ${P4PHP_DIR} + +################################################################## +# Installing PHP8 +################################################################## +RUN wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg && \ + sh -c 'echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list' + +#Install base packages +RUN apt-get update && \ + apt-get install -y --allow-unauthenticated \ + libmemcached-dev \ + smbclient libsmbclient libsmbclient-dev \ + php8.1 \ + php8.1-dev \ + php8.1-fpm \ + php8.1-cli \ + php8.1-cgi + +################################################################## +# preparing p4src +################################################################## +RUN wget -qO - ${P4API_URL} | tar -zxv --strip-components=1 -C ${P4API_DIR} && \ + wget -qO - ${P4API_URL} | tar -zxv --strip-components=1 -C ${MAKE_DIR} && \ + wget -qO - ${P4PHP_URL} | tar -zxv --strip-components=1 -C ${P4PHP_DIR} && \ + wget -qO - ${P4PHP_URL} | tar -zxv --strip-components=1 -C ${MAKE_DIR} && \ + cd ${P4API_DIR} && \ + ls -las && \ + cd ${P4PHP_DIR} && \ + ls -las && \ + cd ${MAKE_DIR} && \ + ls -las && \ + cd ${SRC_DIR} && \ + ls -las + +################################################################## +# compilling p4src +################################################################## +RUN cd ${MAKE_DIR} && \ + ls -las && \ + phpize && \ + ./configure --with-perforce=${P4API_DIR} && \ + make && \ + make test && \ + make install && \ + cp ${PHP_MODULE_PATH}/perforce.so ${EXPORT_DIR} + +################################################################## +# compilling smbclient +################################################################## +RUN pecl install smbclient && \ + cp ${PHP_MODULE_PATH}/smbclient.so ${EXPORT_DIR} + +################################################################## +################################################################## +################################################################## + +FROM epicmorg/edge +LABEL maintainer="EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +ARG PHP_MODULE_VER=20210902 +ARG PHP_MODULE_PATH=/usr/lib/php/${PHP_MODULE_VER} +ARG PHP_VER=8.1 +ARG PHP_DIR=/etc/php/${PHP_VER} +ARG P4_PHP_INI=${PHP_DIR}/mods-available/perfroce.ini +ARG SMB_PHP_INI=${PHP_DIR}/mods-available/smbclient.ini + +################################################################## +# Installing PHP7 +################################################################## +RUN wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg && \ + sh -c 'echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list' + +RUN apt-get update && \ + apt-get install -y --allow-unauthenticated \ + libmemcached-dev \ + php8.1 \ + php8.1-dev \ + php8.1-fpm \ + php8.1-cli \ + php8.1-cgi \ + php-pear \ + php8.1-gmp \ + php8.1-snmp \ + php8.1-ldap \ + php8.1-mail \ + php8.1-soap \ + php8.1-mysql \ + php8.1-memcached \ + php8.1-memcache \ + php8.1-igbinary \ + php8.1-interbase \ + php8.1-curl \ + php8.1-gd \ + php8.1-intl \ + php8.1-zip \ + php8.1-bcmath \ + php8.1-imap \ + php8.1-pspell \ + php8.1-sqlite3 \ + php8.1-pgsql \ + php8.1-tidy \ + php8.1-xmlrpc \ + php8.1-xml \ + php8.1-mbstring \ + php8.1-apcu \ + php8.1-common \ +# php8.1-json \ + php8.1-readline \ + php8.1-enchant \ + php8.1-ssh2 \ + php8.1-oauth \ + php8.1-gmagick \ + php8.1-gnupg \ + php8.1-redis \ + smbclient libsmbclient \ + php8.1-yaml \ +# php8.1-geoip \ + sendmail && \ + ln -sf /etc/ssl/dhparam.pem /etc/php/dhparam.pem && \ + update-alternatives --set php /usr/bin/php8.1 && \ + pecl channel-update pecl.php.net && \ + php -m && \ + php -v + +################################################################## +# Enabling extensions +################################################################## +RUN phpenmod \ + snmp \ + gmp \ + calendar \ + ldap \ + curl \ + exif \ + ftp \ + fileinfo \ + gd \ + geoip \ + gnupg \ + iconv \ + imap \ + json \ + mbstring \ + memcached \ + mysqli \ + mysqlnd \ + oauth \ + pdo_mysql \ + pdo_sqlite \ + phar \ + posix \ + readline \ + redis \ + simplexml \ + sockets \ + sqlite3 \ + ssh2 \ + tokenizer \ + xml \ + xmlreader \ + xmlrpc \ + xmlwriter \ + xsl \ + yaml && \ + php -m && \ + php -v + +################################################################## +# Installing imagic addon +################################################################## +RUN apt-get update && \ + apt-get install -y --allow-unauthenticated \ + libmagickwand-dev \ + imagemagick && \ + pecl install imagick && \ +# echo "extension = ${PHP_MODULE_PATH}/imagick.so" >> ${PHP_DIR}/apache2/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/imagick.so" >> ${PHP_DIR}/cgi/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/imagick.so" >> ${PHP_DIR}/cli/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/imagick.so" >> ${PHP_DIR}/fpm/php.ini && \ + php -m && \ + php -v + +################################################################## +# not supported with php8 +################################################################## +# Installing IOnCube addon +################################################################# +#ADD https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz /tmp/ioncube.tar.gz +#RUN tar -C /tmp -xvf /tmp/ioncube.tar.gz && \ +# cp /tmp/ioncube/ioncube_loader_lin_7.4.so ${PHP_MODULE_PATH} && \ +## echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PHP_DIR}/apache2/php.ini && \ +# echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PHP_DIR}/cgi/php.ini && \ +# echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PHP_DIR}/cli/php.ini && \ +# echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PHP_DIR}/fpm/php.ini && \ +# php -m && \ +# php -v + +################################################################## +# Installing P4 addon +################################################################## +COPY --from=builder /builds/export/perforce.so ${PHP_MODULE_PATH} +RUN echo "extension = ${PHP_MODULE_PATH}/perforce.so" > ${P4_PHP_INI} && \ + ln -sf ${P4_PHP_INI} ${PHP_DIR}/cgi/conf.d/perforce.ini && \ + ln -sf ${P4_PHP_INI} ${PHP_DIR}/cli/conf.d/perforce.ini && \ + ln -sf ${P4_PHP_INI} ${PHP_DIR}/fpm/conf.d/perforce.ini && \ + php -m && \ + php -v + +################################################################## +# Installing smbclient addon +################################################################## +COPY --from=builder /builds/export/smbclient.so ${PHP_MODULE_PATH} +RUN echo "extension = ${PHP_MODULE_PATH}/smbclient.so" > ${SMB_PHP_INI} && \ + ln -sf ${SMB_PHP_INI} ${PHP_DIR}/cgi/conf.d/smbclient.ini && \ + ln -sf ${SMB_PHP_INI} ${PHP_DIR}/cli/conf.d/smbclient.ini && \ + ln -sf ${SMB_PHP_INI} ${PHP_DIR}/fpm/conf.d/smbclient.ini && \ + php -m && \ + php -v + +################################################################## +# Installing Composer addon +################################################################## +RUN cd /tmp && \ + php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" && \ + php composer-setup.php --install-dir=/usr/local/bin --filename=composer && \ + rm /tmp/composer-setup.php + +################################################################## +# cleaninig up +################################################################## +RUN apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb && \ + rm -rfv /tmp/deb/* && \ + rm -rfv /tmp/ioncube/* && \ + rm -rfv /tmp/composer-setup.php && \ + rm -rfv /tmp/ioncube.tar.gz + diff --git a/linux/ecosystem/php/php8.1-p4-not-ready/Makefile b/linux/ecosystem/php/php8.1-p4-not-ready/Makefile new file mode 100644 index 000000000..bad6d73b5 --- /dev/null +++ b/linux/ecosystem/php/php8.1-p4-not-ready/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel + +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/php/php8.1-p4-not-ready/README.md b/linux/ecosystem/php/php8.1-p4-not-ready/README.md new file mode 100644 index 000000000..e69de29bb diff --git a/linux/ecosystem/php/php8.1-p4-not-ready/docker-compose.yml b/linux/ecosystem/php/php8.1-p4-not-ready/docker-compose.yml new file mode 100644 index 000000000..85e910794 --- /dev/null +++ b/linux/ecosystem/php/php8.1-p4-not-ready/docker-compose.yml @@ -0,0 +1,6 @@ +version: '3.9' +services: + app: + image: "epicmorg/php:php8.1" + build: + context: . From 6df47829b3867bb1e4109f8b17c8aac7901b3051 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Tue, 25 Jan 2022 13:22:18 +0300 Subject: [PATCH 12/20] timezonedb php fixes --- linux/ecosystem/apache2/latest/Dockerfile | 7 ++ linux/ecosystem/apache2/php7.2/Dockerfile | 7 ++ linux/ecosystem/apache2/php7.3/Dockerfile | 7 ++ linux/ecosystem/apache2/php7.4/Dockerfile | 7 ++ linux/ecosystem/apache2/php8.0/Dockerfile | 113 ++++++++++++++++++ linux/ecosystem/apache2/php8.0/Makefile | 19 +++ linux/ecosystem/apache2/php8.0/README.md | 32 +++++ .../apache2/php8.0/docker-compose.yml | 6 + linux/ecosystem/apache2/php8.0/run.sh | 7 ++ linux/ecosystem/php/latest/Dockerfile | 11 ++ linux/ecosystem/php/php7.2/Dockerfile | 11 ++ linux/ecosystem/php/php7.3/Dockerfile | 11 ++ linux/ecosystem/php/php7.4/Dockerfile | 11 ++ linux/ecosystem/php/php8.0/Dockerfile | 13 +- .../php/php8.1-p4-not-ready/Dockerfile | 13 +- 15 files changed, 273 insertions(+), 2 deletions(-) create mode 100644 linux/ecosystem/apache2/php8.0/Dockerfile create mode 100644 linux/ecosystem/apache2/php8.0/Makefile create mode 100644 linux/ecosystem/apache2/php8.0/README.md create mode 100644 linux/ecosystem/apache2/php8.0/docker-compose.yml create mode 100755 linux/ecosystem/apache2/php8.0/run.sh diff --git a/linux/ecosystem/apache2/latest/Dockerfile b/linux/ecosystem/apache2/latest/Dockerfile index c7a49b75e..db8a92b9e 100644 --- a/linux/ecosystem/apache2/latest/Dockerfile +++ b/linux/ecosystem/apache2/latest/Dockerfile @@ -59,6 +59,13 @@ RUN echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PH php -m && \ php -v +################################################################## +# Installing timezonedb addon +################################################################## +RUN echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini && \ + php -m && \ + php -v + ################################################################## # Installing imagic addon ################################################################## diff --git a/linux/ecosystem/apache2/php7.2/Dockerfile b/linux/ecosystem/apache2/php7.2/Dockerfile index d653289ec..ae31ddbc1 100644 --- a/linux/ecosystem/apache2/php7.2/Dockerfile +++ b/linux/ecosystem/apache2/php7.2/Dockerfile @@ -59,6 +59,13 @@ RUN echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.2.so" >> ${PH php -m && \ php -v +################################################################## +# Installing timezonedb addon +################################################################## +RUN echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini && \ + php -m && \ + php -v + ################################################################## # Installing imagic addon ################################################################## diff --git a/linux/ecosystem/apache2/php7.3/Dockerfile b/linux/ecosystem/apache2/php7.3/Dockerfile index 4f71b5beb..7848e964a 100644 --- a/linux/ecosystem/apache2/php7.3/Dockerfile +++ b/linux/ecosystem/apache2/php7.3/Dockerfile @@ -59,6 +59,13 @@ RUN echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.3.so" >> ${P php -m && \ php -v +################################################################## +# Installing timezonedb addon +################################################################## +RUN echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini & \ + php -m && \ + php -v + ################################################################## # Installing imagic addon ################################################################## diff --git a/linux/ecosystem/apache2/php7.4/Dockerfile b/linux/ecosystem/apache2/php7.4/Dockerfile index c7a49b75e..db8a92b9e 100644 --- a/linux/ecosystem/apache2/php7.4/Dockerfile +++ b/linux/ecosystem/apache2/php7.4/Dockerfile @@ -59,6 +59,13 @@ RUN echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PH php -m && \ php -v +################################################################## +# Installing timezonedb addon +################################################################## +RUN echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini && \ + php -m && \ + php -v + ################################################################## # Installing imagic addon ################################################################## diff --git a/linux/ecosystem/apache2/php8.0/Dockerfile b/linux/ecosystem/apache2/php8.0/Dockerfile new file mode 100644 index 000000000..044d2e2bf --- /dev/null +++ b/linux/ecosystem/apache2/php8.0/Dockerfile @@ -0,0 +1,113 @@ +FROM epicmorg/php:php8.0 +LABEL maintainer="EpicMorg DevTeam, developer@epicm.org" +ARG DEBIAN_FRONTEND=noninteractive + +ARG PHP_MODULE_VER=20200930 +ARG PHP_MODULE_PATH=/usr/lib/php/${PHP_MODULE_VER} +ARG PHP_VER=8.0 +ARG PHP_DIR=/etc/php/${PHP_VER} +ARG P4_PHP_INI=${PHP_DIR}/mods-available/perfroce.ini +ARG SMB_PHP_INI=${PHP_DIR}/mods-available/smbclient.ini + +################################################################## +# Installing Apache2 +################################################################## +#installing apache2 repo +RUN wget -O /etc/apt/trusted.gpg.d/apache2.gpg https://packages.sury.org/apache2/apt.gpg +RUN sh -c 'echo "deb https://packages.sury.org/apache2/ buster main" > /etc/apt/sources.list.d/apache2.list' + +#Install base packages +RUN apt-get update && \ + apt-get install -y --allow-unauthenticated \ + apache2 \ + apache2-utils \ + libapache2-mod-php8.0 \ + libapache2-mod-webauth \ + libapache2-mod-xforward \ + libapache2-mod-security2 && \ + a2enmod \ + php8.0 \ + rewrite \ + ldap \ + heartmonitor \ + auth_basic \ + authnz_ldap \ + headers \ + heartbeat \ + lua \ + mime \ + status \ + xml2enc \ + xforward \ + remoteip \ + filter \ + dav \ + dav_fs \ + alias && \ + ln -sf /etc/ssl/dhparam.pem /etc/apache2/dhparam.pem && \ + php -m && \ + php -v + +################################################################## +# LDAP Fix +################################################################## +RUN echo "TLS_REQCERT never" >> /etc/ldap/ldap.conf + +################################################################## +# Installing IOnCube addon +################################################################## +RUN echo "zend_extension = ${PHP_MODULE_PATH}/ioncube_loader_lin_7.4.so" >> ${PHP_DIR}/apache2/php.ini && \ + php -m && \ + php -v + +################################################################## +# Installing timezonedb addon +################################################################## +RUN echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini && \ + php -m && \ + php -v + +################################################################## +# Installing imagic addon +################################################################## +RUN echo "extension = ${PHP_MODULE_PATH}/imagick.so" >> ${PHP_DIR}/apache2/php.ini && \ + php -m && \ + php -v + +################################################################## +# Installing P4 addon +################################################################## +RUN ln -sf ${P4_PHP_INI} ${PHP_DIR}/apache2/conf.d/perforce.ini && \ + php -m && \ + php -v + +################################################################## +# Installing smbclient addon +################################################################## +RUN ln -sf ${SMB_PHP_INI} ${PHP_DIR}/apache2/conf.d/smbclient.ini && \ + php -m && \ + php -v + +################################################################## +# cleaninig up +################################################################## +RUN apt clean -y && \ + apt autoclean -y && \ + rm -rfv /var/lib/apt/lists/* && \ + rm -rfv /var/cache/apt/archives/*.deb && \ + rm -rfv /tmp/deb/* && \ + rm -rfv /tmp/ioncube/* && \ + rm -rfv /tmp/composer-setup.php && \ + rm -rfv /tmp/ioncube.tar.gz + +#volumes +VOLUME ["/var/www"] + +# Add image configuration and scripts +COPY run.sh /run.sh +RUN chmod 755 /*.sh + +# Configure application +EXPOSE 80 +WORKDIR /var/www/ +CMD ["/run.sh"] diff --git a/linux/ecosystem/apache2/php8.0/Makefile b/linux/ecosystem/apache2/php8.0/Makefile new file mode 100644 index 000000000..bad6d73b5 --- /dev/null +++ b/linux/ecosystem/apache2/php8.0/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel + +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/apache2/php8.0/README.md b/linux/ecosystem/apache2/php8.0/README.md new file mode 100644 index 000000000..86a34d4b1 --- /dev/null +++ b/linux/ecosystem/apache2/php8.0/README.md @@ -0,0 +1,32 @@ +# Compose example + +```yml +version: '3.7' +services: + websites: + image: epicmorg/websites +# depends_on: +# - mysql +# - memcached + restart: unless-stopped + volumes: + - /etc/localtime:/etc/localtime + - /etc/timezone:/etc/timezone +# - /etc/letsencrypt:/etc/letsencrypt + - www:/var/www + - apache2:/etc/apache2 + - php:/etc/php + restart: unless-stopped +# extra_hosts: +# - "example.com:192.168.0.11" + tmpfs: + - /tmp + - /var/lib/php/sessions +volumes: + www: + external: true + apache2: + external: true + php: + external: true +``` diff --git a/linux/ecosystem/apache2/php8.0/docker-compose.yml b/linux/ecosystem/apache2/php8.0/docker-compose.yml new file mode 100644 index 000000000..e6723b69c --- /dev/null +++ b/linux/ecosystem/apache2/php8.0/docker-compose.yml @@ -0,0 +1,6 @@ +version: '3.9' +services: + app: + image: "epicmorg/apache2:php7.4" + build: + context: . diff --git a/linux/ecosystem/apache2/php8.0/run.sh b/linux/ecosystem/apache2/php8.0/run.sh new file mode 100755 index 000000000..6bc50582d --- /dev/null +++ b/linux/ecosystem/apache2/php8.0/run.sh @@ -0,0 +1,7 @@ +#!/bin/bash +echo "Changing permissions for /var/www path. Dont worry, please wait." +chown www-data:www-data /var/www -R +echo "Done. Starting up" +source /etc/apache2/envvars +tail -F /var/log/apache2/* & +exec apache2 -D FOREGROUND diff --git a/linux/ecosystem/php/latest/Dockerfile b/linux/ecosystem/php/latest/Dockerfile index f687b4472..0b85b466e 100644 --- a/linux/ecosystem/php/latest/Dockerfile +++ b/linux/ecosystem/php/latest/Dockerfile @@ -187,6 +187,17 @@ RUN phpenmod \ php -m && \ php -v +################################################################## +# Installing timezonedb addon +################################################################## +RUN pecl install timezonedb && \ +# echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cgi/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cli/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/fpm/php.ini && \ + php -m && \ + php -v + ################################################################## # Installing imagic addon ################################################################## diff --git a/linux/ecosystem/php/php7.2/Dockerfile b/linux/ecosystem/php/php7.2/Dockerfile index 91d279a62..aba6eb87d 100644 --- a/linux/ecosystem/php/php7.2/Dockerfile +++ b/linux/ecosystem/php/php7.2/Dockerfile @@ -177,6 +177,17 @@ RUN phpenmod \ php -m && \ php -v +################################################################## +# Installing timezonedb addon +################################################################## +RUN pecl install timezonedb && \ +# echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cgi/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cli/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/fpm/php.ini && \ + php -m && \ + php -v + ################################################################## # Installing imagic addon ################################################################## diff --git a/linux/ecosystem/php/php7.3/Dockerfile b/linux/ecosystem/php/php7.3/Dockerfile index 36dec8493..ff42b5c4d 100644 --- a/linux/ecosystem/php/php7.3/Dockerfile +++ b/linux/ecosystem/php/php7.3/Dockerfile @@ -184,6 +184,17 @@ RUN phpenmod \ php -m && \ php -v +################################################################## +# Installing timezonedb addon +################################################################## +RUN pecl install timezonedb && \ +# echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cgi/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cli/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/fpm/php.ini && \ + php -m && \ + php -v + ################################################################## # Installing imagic addon ################################################################## diff --git a/linux/ecosystem/php/php7.4/Dockerfile b/linux/ecosystem/php/php7.4/Dockerfile index f687b4472..0b85b466e 100644 --- a/linux/ecosystem/php/php7.4/Dockerfile +++ b/linux/ecosystem/php/php7.4/Dockerfile @@ -187,6 +187,17 @@ RUN phpenmod \ php -m && \ php -v +################################################################## +# Installing timezonedb addon +################################################################## +RUN pecl install timezonedb && \ +# echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cgi/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cli/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/fpm/php.ini && \ + php -m && \ + php -v + ################################################################## # Installing imagic addon ################################################################## diff --git a/linux/ecosystem/php/php8.0/Dockerfile b/linux/ecosystem/php/php8.0/Dockerfile index 178949c90..1c1d2c467 100644 --- a/linux/ecosystem/php/php8.0/Dockerfile +++ b/linux/ecosystem/php/php8.0/Dockerfile @@ -96,7 +96,7 @@ ARG P4_PHP_INI=${PHP_DIR}/mods-available/perfroce.ini ARG SMB_PHP_INI=${PHP_DIR}/mods-available/smbclient.ini ################################################################## -# Installing PHP7 +# Installing PHP8 ################################################################## RUN wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg && \ sh -c 'echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list' @@ -196,6 +196,17 @@ RUN phpenmod \ php -m && \ php -v +################################################################## +# Installing timezonedb addon +################################################################## +RUN pecl install timezonedb && \ +# echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cgi/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cli/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/fpm/php.ini && \ + php -m && \ + php -v + ################################################################## # Installing imagic addon ################################################################## diff --git a/linux/ecosystem/php/php8.1-p4-not-ready/Dockerfile b/linux/ecosystem/php/php8.1-p4-not-ready/Dockerfile index 8c72b3fa9..76fc73fcc 100644 --- a/linux/ecosystem/php/php8.1-p4-not-ready/Dockerfile +++ b/linux/ecosystem/php/php8.1-p4-not-ready/Dockerfile @@ -96,7 +96,7 @@ ARG P4_PHP_INI=${PHP_DIR}/mods-available/perfroce.ini ARG SMB_PHP_INI=${PHP_DIR}/mods-available/smbclient.ini ################################################################## -# Installing PHP7 +# Installing PHP8 ################################################################## RUN wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg && \ sh -c 'echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list' @@ -196,6 +196,17 @@ RUN phpenmod \ php -m && \ php -v +################################################################## +# Installing timezonedb addon +################################################################## +RUN pecl install timezonedb && \ +# echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/apache2/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cgi/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/cli/php.ini && \ + echo "extension = ${PHP_MODULE_PATH}/timezonedb.so" >> ${PHP_DIR}/fpm/php.ini && \ + php -m && \ + php -v + ################################################################## # Installing imagic addon ################################################################## From 0f45904f2e436ad349c96dfd3b0ede3af57cead1 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Tue, 25 Jan 2022 15:29:43 +0300 Subject: [PATCH 13/20] apache2 startup fix --- linux/ecosystem/apache2/latest/run.sh | 17 ++++++++++++++--- linux/ecosystem/apache2/php7.2/run.sh | 17 ++++++++++++++--- linux/ecosystem/apache2/php7.3/run.sh | 17 ++++++++++++++--- linux/ecosystem/apache2/php7.4/run.sh | 17 ++++++++++++++--- linux/ecosystem/apache2/php8.0/run.sh | 17 ++++++++++++++--- 5 files changed, 70 insertions(+), 15 deletions(-) diff --git a/linux/ecosystem/apache2/latest/run.sh b/linux/ecosystem/apache2/latest/run.sh index 6bc50582d..b421b8648 100755 --- a/linux/ecosystem/apache2/latest/run.sh +++ b/linux/ecosystem/apache2/latest/run.sh @@ -1,7 +1,18 @@ #!/bin/bash -echo "Changing permissions for /var/www path. Dont worry, please wait." -chown www-data:www-data /var/www -R -echo "Done. Starting up" + +if [[ -z "${FIX_WWW_DATA}" ]]; then + echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." +elif [ "${FIX_WWW_DATA}" == "false" ]; then + echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." +elif [ "${FIX_WWW_DATA}" == "true" ]; then + echo "[apache2] Changing permissions for /var/www path. Dont worry, please wait." + chown www-data:www-data /var/www -R + echo "[apache2] Done" +else + echo "[apache2] env FIX_WWW_DATA is set to strange value. Skipping..." +fi + +echo "[apache2] Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & exec apache2 -D FOREGROUND diff --git a/linux/ecosystem/apache2/php7.2/run.sh b/linux/ecosystem/apache2/php7.2/run.sh index 6bc50582d..b421b8648 100755 --- a/linux/ecosystem/apache2/php7.2/run.sh +++ b/linux/ecosystem/apache2/php7.2/run.sh @@ -1,7 +1,18 @@ #!/bin/bash -echo "Changing permissions for /var/www path. Dont worry, please wait." -chown www-data:www-data /var/www -R -echo "Done. Starting up" + +if [[ -z "${FIX_WWW_DATA}" ]]; then + echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." +elif [ "${FIX_WWW_DATA}" == "false" ]; then + echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." +elif [ "${FIX_WWW_DATA}" == "true" ]; then + echo "[apache2] Changing permissions for /var/www path. Dont worry, please wait." + chown www-data:www-data /var/www -R + echo "[apache2] Done" +else + echo "[apache2] env FIX_WWW_DATA is set to strange value. Skipping..." +fi + +echo "[apache2] Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & exec apache2 -D FOREGROUND diff --git a/linux/ecosystem/apache2/php7.3/run.sh b/linux/ecosystem/apache2/php7.3/run.sh index 6bc50582d..b421b8648 100755 --- a/linux/ecosystem/apache2/php7.3/run.sh +++ b/linux/ecosystem/apache2/php7.3/run.sh @@ -1,7 +1,18 @@ #!/bin/bash -echo "Changing permissions for /var/www path. Dont worry, please wait." -chown www-data:www-data /var/www -R -echo "Done. Starting up" + +if [[ -z "${FIX_WWW_DATA}" ]]; then + echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." +elif [ "${FIX_WWW_DATA}" == "false" ]; then + echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." +elif [ "${FIX_WWW_DATA}" == "true" ]; then + echo "[apache2] Changing permissions for /var/www path. Dont worry, please wait." + chown www-data:www-data /var/www -R + echo "[apache2] Done" +else + echo "[apache2] env FIX_WWW_DATA is set to strange value. Skipping..." +fi + +echo "[apache2] Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & exec apache2 -D FOREGROUND diff --git a/linux/ecosystem/apache2/php7.4/run.sh b/linux/ecosystem/apache2/php7.4/run.sh index 6bc50582d..b421b8648 100755 --- a/linux/ecosystem/apache2/php7.4/run.sh +++ b/linux/ecosystem/apache2/php7.4/run.sh @@ -1,7 +1,18 @@ #!/bin/bash -echo "Changing permissions for /var/www path. Dont worry, please wait." -chown www-data:www-data /var/www -R -echo "Done. Starting up" + +if [[ -z "${FIX_WWW_DATA}" ]]; then + echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." +elif [ "${FIX_WWW_DATA}" == "false" ]; then + echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." +elif [ "${FIX_WWW_DATA}" == "true" ]; then + echo "[apache2] Changing permissions for /var/www path. Dont worry, please wait." + chown www-data:www-data /var/www -R + echo "[apache2] Done" +else + echo "[apache2] env FIX_WWW_DATA is set to strange value. Skipping..." +fi + +echo "[apache2] Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & exec apache2 -D FOREGROUND diff --git a/linux/ecosystem/apache2/php8.0/run.sh b/linux/ecosystem/apache2/php8.0/run.sh index 6bc50582d..b421b8648 100755 --- a/linux/ecosystem/apache2/php8.0/run.sh +++ b/linux/ecosystem/apache2/php8.0/run.sh @@ -1,7 +1,18 @@ #!/bin/bash -echo "Changing permissions for /var/www path. Dont worry, please wait." -chown www-data:www-data /var/www -R -echo "Done. Starting up" + +if [[ -z "${FIX_WWW_DATA}" ]]; then + echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." +elif [ "${FIX_WWW_DATA}" == "false" ]; then + echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." +elif [ "${FIX_WWW_DATA}" == "true" ]; then + echo "[apache2] Changing permissions for /var/www path. Dont worry, please wait." + chown www-data:www-data /var/www -R + echo "[apache2] Done" +else + echo "[apache2] env FIX_WWW_DATA is set to strange value. Skipping..." +fi + +echo "[apache2] Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & exec apache2 -D FOREGROUND From 232be1ea7f4c3694083f97948845f9a388fb1ac6 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Tue, 25 Jan 2022 16:19:14 +0300 Subject: [PATCH 14/20] apache2 php8 fix --- linux/ecosystem/apache2/php8.0/docker-compose.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linux/ecosystem/apache2/php8.0/docker-compose.yml b/linux/ecosystem/apache2/php8.0/docker-compose.yml index e6723b69c..608acd24c 100644 --- a/linux/ecosystem/apache2/php8.0/docker-compose.yml +++ b/linux/ecosystem/apache2/php8.0/docker-compose.yml @@ -1,6 +1,6 @@ version: '3.9' services: app: - image: "epicmorg/apache2:php7.4" + image: "epicmorg/apache2:php8.0" build: context: . From 4efd7b680c1b02a666b2be624dd514e85e858a40 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Tue, 25 Jan 2022 16:19:37 +0300 Subject: [PATCH 15/20] testrail fixes --- linux/ecosystem/testrail/{ => ad}/Dockerfile | 2 +- linux/ecosystem/testrail/{ => ad}/Makefile | 0 linux/ecosystem/testrail/{ => ad}/README.md | 0 .../ecosystem/testrail/ad/docker-compose.yml | 6 +++ linux/ecosystem/testrail/latest/Dockerfile | 45 +++++++++++++++++++ linux/ecosystem/testrail/latest/Makefile | 19 ++++++++ linux/ecosystem/testrail/latest/README.md | 36 +++++++++++++++ .../{ => latest}/apache_testrail.conf | 0 .../testrail/{ => latest}/docker-compose.yml | 0 linux/ecosystem/testrail/{ => latest}/run.sh | 0 10 files changed, 107 insertions(+), 1 deletion(-) rename linux/ecosystem/testrail/{ => ad}/Dockerfile (97%) rename linux/ecosystem/testrail/{ => ad}/Makefile (100%) rename linux/ecosystem/testrail/{ => ad}/README.md (100%) create mode 100644 linux/ecosystem/testrail/ad/docker-compose.yml create mode 100644 linux/ecosystem/testrail/latest/Dockerfile create mode 100644 linux/ecosystem/testrail/latest/Makefile create mode 100644 linux/ecosystem/testrail/latest/README.md rename linux/ecosystem/testrail/{ => latest}/apache_testrail.conf (100%) rename linux/ecosystem/testrail/{ => latest}/docker-compose.yml (100%) rename linux/ecosystem/testrail/{ => latest}/run.sh (100%) diff --git a/linux/ecosystem/testrail/Dockerfile b/linux/ecosystem/testrail/ad/Dockerfile similarity index 97% rename from linux/ecosystem/testrail/Dockerfile rename to linux/ecosystem/testrail/ad/Dockerfile index 333409e38..5831be237 100644 --- a/linux/ecosystem/testrail/Dockerfile +++ b/linux/ecosystem/testrail/ad/Dockerfile @@ -1,7 +1,7 @@ FROM epicmorg/apache2:php7.4 ARG TESTRAIL_VERSION=latest -ARG DOWNLOAD_URL=https://secure.gurock.com/downloads/testrail/testrail-${TESTRAIL_VERSION}-ion71.zip +ARG DOWNLOAD_URL=https://secure.gurock.com/downloads/testrail/testrail-${TESTRAIL_VERSION}-ion72.zip ARG TESTRAIL_RELEASE_DIR=testrail-release ENV TR_DEFAULT_TASK_EXECUTION=60 diff --git a/linux/ecosystem/testrail/Makefile b/linux/ecosystem/testrail/ad/Makefile similarity index 100% rename from linux/ecosystem/testrail/Makefile rename to linux/ecosystem/testrail/ad/Makefile diff --git a/linux/ecosystem/testrail/README.md b/linux/ecosystem/testrail/ad/README.md similarity index 100% rename from linux/ecosystem/testrail/README.md rename to linux/ecosystem/testrail/ad/README.md diff --git a/linux/ecosystem/testrail/ad/docker-compose.yml b/linux/ecosystem/testrail/ad/docker-compose.yml new file mode 100644 index 000000000..0cf4314f7 --- /dev/null +++ b/linux/ecosystem/testrail/ad/docker-compose.yml @@ -0,0 +1,6 @@ +version: '3.9' +services: + app: + image: "epicmorg/testrail:auth-ad" + build: + context: . diff --git a/linux/ecosystem/testrail/latest/Dockerfile b/linux/ecosystem/testrail/latest/Dockerfile new file mode 100644 index 000000000..ee1bf08bb --- /dev/null +++ b/linux/ecosystem/testrail/latest/Dockerfile @@ -0,0 +1,45 @@ +FROM epicmorg/apache2:php7.4 + +ARG TESTRAIL_VERSION=latest +ARG DOWNLOAD_URL=https://secure.gurock.com/downloads/testrail/testrail-${TESTRAIL_VERSION}-ion72.zip +ARG TESTRAIL_RELEASE_DIR=testrail-release + +ENV TR_DEFAULT_TASK_EXECUTION=60 +ENV TR_WWWPATH="/var/www/testrail/" +ENV TR_CONFIGPATH="/var/www/testrail/config/" +ENV TR_CUSTOM_DIR="/var/www/testrail/custom/" +ENV TR_CUSTOM_AUTH_DIR="/var/www/testrail/custom/auth/" + +ENV TR_OPTPATH="/opt/testrail/" +ENV TR_DEFAULT_LOG_DIR="/opt/testrail/logs/" +ENV TR_DEFAULT_AUDIT_DIR="/opt/testrail/audit/" +ENV TR_DEFAULT_REPORT_DIR="/opt/testrail/reports/" +ENV TR_DEFAULT_ATTACHMENT_DIR="/opt/testrail/attachments/" +ENV OPENSSL_CONF=/etc/ssl/ + +RUN \ + apt-get update && \ + apt-get install -y --no-install-recommends zlib1g-dev libcurl4-gnutls-dev libldap2-dev zlib1g-dev libxml2-dev libfontconfig1 && \ + apt-get clean && \ + rm -rf /var/lib/apt/lists/* && \ + rm -rf /run.sh + + +RUN \ + echo "WGET" && \ + mkdir -p /${TESTRAIL_RELEASE_DIR} && \ + mkdir -p /var/www/testrail && \ + mkdir -p /opt/testrail/attachments /opt/testrail/reports /opt/testrail/logs /opt/testrail/audit && \ + wget --no-check-certificate -O /${TESTRAIL_RELEASE_DIR}/testrail.zip ${DOWNLOAD_URL} && \ + chown -R www-data:www-data /${TESTRAIL_RELEASE_DIR} && \ + chown -R www-data:www-data /var/www/testrail && \ + chown -R www-data:www-data /opt/testrail + + +COPY apache_testrail.conf /${TESTRAIL_RELEASE_DIR}/apache-conf/000-default.conf +COPY run.sh /run.sh + +WORKDIR /var/www/testrail +EXPOSE 80 + +CMD ["/run.sh"] \ No newline at end of file diff --git a/linux/ecosystem/testrail/latest/Makefile b/linux/ecosystem/testrail/latest/Makefile new file mode 100644 index 000000000..bad6d73b5 --- /dev/null +++ b/linux/ecosystem/testrail/latest/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel + +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/testrail/latest/README.md b/linux/ecosystem/testrail/latest/README.md new file mode 100644 index 000000000..1aae0e92d --- /dev/null +++ b/linux/ecosystem/testrail/latest/README.md @@ -0,0 +1,36 @@ +## Testrail + +* Based on `websites:php7.2` of our ecosystem. + +# Compose example + +```yml +version: '3.7' +services: + testrail: + image: epicmorg/testrail +# depends_on: +# - mysql +# - memcached + restart: unless-stopped + volumes: + - /etc/localtime:/etc/localtime + - /etc/timezone:/etc/timezone +# - /etc/letsencrypt:/etc/letsencrypt + - www:/var/www + - apache2:/etc/apache2 + - php:/etc/php + restart: unless-stopped +# extra_hosts: +# - "example.com:192.168.0.11" + tmpfs: + - /tmp + - /var/lib/php/sessions +volumes: + www: + external: true + apache2: + external: true + php: + external: true +``` diff --git a/linux/ecosystem/testrail/apache_testrail.conf b/linux/ecosystem/testrail/latest/apache_testrail.conf similarity index 100% rename from linux/ecosystem/testrail/apache_testrail.conf rename to linux/ecosystem/testrail/latest/apache_testrail.conf diff --git a/linux/ecosystem/testrail/docker-compose.yml b/linux/ecosystem/testrail/latest/docker-compose.yml similarity index 100% rename from linux/ecosystem/testrail/docker-compose.yml rename to linux/ecosystem/testrail/latest/docker-compose.yml diff --git a/linux/ecosystem/testrail/run.sh b/linux/ecosystem/testrail/latest/run.sh similarity index 100% rename from linux/ecosystem/testrail/run.sh rename to linux/ecosystem/testrail/latest/run.sh From 9c37f26f5a4dcdf9c871020de86a9e47e16b26cc Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Tue, 25 Jan 2022 19:01:36 +0300 Subject: [PATCH 16/20] updates jan'22 --- CHANGELOG.md | 5 ++ linux/ecosystem/testrail/ad/Dockerfile | 45 ++++------------- linux/ecosystem/testrail/ad/run.sh | 49 +++++++++++++++++++ linux/ecosystem/testrail/latest/Dockerfile | 4 +- linux/ecosystem/testrail/latest/run.sh | 4 +- linux/ecosystem/testrail/ldap/Dockerfile | 15 ++++++ linux/ecosystem/testrail/ldap/Makefile | 19 +++++++ linux/ecosystem/testrail/ldap/README.md | 36 ++++++++++++++ .../testrail/ldap/docker-compose.yml | 6 +++ linux/ecosystem/testrail/ldap/run.sh | 47 ++++++++++++++++++ 10 files changed, 191 insertions(+), 39 deletions(-) create mode 100755 linux/ecosystem/testrail/ad/run.sh create mode 100644 linux/ecosystem/testrail/ldap/Dockerfile create mode 100644 linux/ecosystem/testrail/ldap/Makefile create mode 100644 linux/ecosystem/testrail/ldap/README.md create mode 100644 linux/ecosystem/testrail/ldap/docker-compose.yml create mode 100755 linux/ecosystem/testrail/ldap/run.sh diff --git a/CHANGELOG.md b/CHANGELOG.md index 9663faedd..8a711e75c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,9 @@ ## Changelog +### 2022 +* `january` + * fixed `apache2` + * added `php8` support + * extended `testrail` releases with `active directory` and `ldap` auth support. ### 2021 * `december` * added `git-lfs`, `lazygit`, bumped versions of nginx, jira, conflunce and bitbucket. diff --git a/linux/ecosystem/testrail/ad/Dockerfile b/linux/ecosystem/testrail/ad/Dockerfile index 5831be237..d302559d6 100644 --- a/linux/ecosystem/testrail/ad/Dockerfile +++ b/linux/ecosystem/testrail/ad/Dockerfile @@ -1,40 +1,15 @@ -FROM epicmorg/apache2:php7.4 +FROM epicmorg/testrail:latest -ARG TESTRAIL_VERSION=latest -ARG DOWNLOAD_URL=https://secure.gurock.com/downloads/testrail/testrail-${TESTRAIL_VERSION}-ion72.zip -ARG TESTRAIL_RELEASE_DIR=testrail-release +ARG TESTRAIL_RELEASE_DIR=/testrail-release -ENV TR_DEFAULT_TASK_EXECUTION=60 -ENV TR_CONFIGPATH="/var/www/testrail/config/" -ENV TR_DEFAULT_LOG_DIR="/opt/testrail/logs/" -ENV TR_DEFAULT_AUDIT_DIR="/opt/testrail/audit/" -ENV TR_DEFAULT_REPORT_DIR="/opt/testrail/reports/" -ENV TR_DEFAULT_ATTACHMENT_DIR="/opt/testrail/attachments/" -ENV OPENSSL_CONF=/etc/ssl/ +ARG TESTRAIL_PLUGIN_VERSION=1.4 +ARG TESTRAIL_PLUGIN_NAME=ad +ARG TESTRAIL_PLUGIN_FULLNAME=testrail-auth-${TESTRAIL_PLUGIN_NAME}-${TESTRAIL_PLUGIN_VERSION} +ARG TESTRAIL_PLUGIN_FILE=${TESTRAIL_PLUGIN_FULLNAME}.zip +ARG TESTRAIL_PLUGIN_DONWLOAD_URL=https://media.gurock.com/gk-media/downloads/${TESTRAIL_PLUGIN_FILE} +ARG TESTRAIL_PLUGIN_TEMP=${TESTRAIL_RELEASE_DIR}/${TESTRAIL_PLUGIN_FILE} -RUN \ - apt-get update && \ - apt-get install -y --no-install-recommends zlib1g-dev libcurl4-gnutls-dev libldap2-dev zlib1g-dev libxml2-dev libfontconfig1 && \ - apt-get clean && \ - rm -rf /var/lib/apt/lists/* && \ - rm -rf /run.sh - - -RUN \ - echo "WGET" && \ - mkdir -p /${TESTRAIL_RELEASE_DIR} && \ - mkdir -p /var/www/testrail && \ - mkdir -p /opt/testrail/attachments /opt/testrail/reports /opt/testrail/logs /opt/testrail/audit && \ - wget --no-check-certificate -O /${TESTRAIL_RELEASE_DIR}/testrail.zip ${DOWNLOAD_URL} && \ - chown -R www-data:www-data /${TESTRAIL_RELEASE_DIR} && \ - chown -R www-data:www-data /var/www/testrail && \ - chown -R www-data:www-data /opt/testrail - - -COPY apache_testrail.conf /${TESTRAIL_RELEASE_DIR}/apache-conf/000-default.conf +RUN rm -rfv /run.sh COPY run.sh /run.sh -WORKDIR /var/www/testrail -EXPOSE 80 - -CMD ["/run.sh"] \ No newline at end of file +RUN wget --no-check-certificate -O ${TESTRAIL_PLUGIN_TEMP} ${TESTRAIL_PLUGIN_DONWLOAD_URL} diff --git a/linux/ecosystem/testrail/ad/run.sh b/linux/ecosystem/testrail/ad/run.sh new file mode 100755 index 000000000..f8ce8f0f1 --- /dev/null +++ b/linux/ecosystem/testrail/ad/run.sh @@ -0,0 +1,49 @@ +#!/bin/bash +#set -e + +function createOptDirectory { + if [ ! -d $1 ] + then + echo "Creating " $1 + mkdir -p $1 + fi + + chown -R www-data:www-data $1 +} + +/bin/cp -rf /testrail-release/apache-conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf + +echo "##############" +echo "Unzipping testrail" +unzip -o /testrail-release/testrail.zip -d /var/www/ +unzip -o -j /testrail-release/testrail-auth-ad-1.4.zip testrail-auth-ad-1.4/auth.php -d ${TR_CUSTOM_AUTH_DIR} && \ +ls -las ${TR_CUSTOM_AUTH_DIR} + + + +createOptDirectory $TR_DEFAULT_LOG_DIR +createOptDirectory $TR_DEFAULT_AUDIT_DIR +createOptDirectory $TR_DEFAULT_REPORT_DIR +createOptDirectory $TR_DEFAULT_ATTACHMENT_DIR + +chown -R www-data:www-data /var/www/testrail/config + +echo "##############" +echo "Waiting for background task file" +while [ ! -f /var/www/testrail/task.php ] +do + sleep 2 +done + +echo "Starting background task" +while /bin/true; do + php /var/www/testrail/task.php || true + sleep $TR_DEFAULT_TASK_EXECUTION +done & +echo "##############" + +chown www-data:www-data /var/www -R + +source /etc/apache2/envvars +tail -F /var/log/apache2/* & +exec apache2 -D FOREGROUND diff --git a/linux/ecosystem/testrail/latest/Dockerfile b/linux/ecosystem/testrail/latest/Dockerfile index ee1bf08bb..f22c012c2 100644 --- a/linux/ecosystem/testrail/latest/Dockerfile +++ b/linux/ecosystem/testrail/latest/Dockerfile @@ -32,6 +32,8 @@ RUN \ mkdir -p /opt/testrail/attachments /opt/testrail/reports /opt/testrail/logs /opt/testrail/audit && \ wget --no-check-certificate -O /${TESTRAIL_RELEASE_DIR}/testrail.zip ${DOWNLOAD_URL} && \ chown -R www-data:www-data /${TESTRAIL_RELEASE_DIR} && \ + unzip -o /testrail-release/testrail.zip -d /var/www/ && \ + ls -las /var/www/testrail && \ chown -R www-data:www-data /var/www/testrail && \ chown -R www-data:www-data /opt/testrail @@ -42,4 +44,4 @@ COPY run.sh /run.sh WORKDIR /var/www/testrail EXPOSE 80 -CMD ["/run.sh"] \ No newline at end of file +CMD ["/run.sh"] diff --git a/linux/ecosystem/testrail/latest/run.sh b/linux/ecosystem/testrail/latest/run.sh index 8de0f623d..cc5e6118d 100755 --- a/linux/ecosystem/testrail/latest/run.sh +++ b/linux/ecosystem/testrail/latest/run.sh @@ -15,17 +15,15 @@ function createOptDirectory { echo "##############" echo "Unzipping testrail" -unzip /testrail-release/testrail.zip -d /var/www/ +unzip -o /testrail-release/testrail.zip -d /var/www/ createOptDirectory $TR_DEFAULT_LOG_DIR createOptDirectory $TR_DEFAULT_AUDIT_DIR createOptDirectory $TR_DEFAULT_REPORT_DIR createOptDirectory $TR_DEFAULT_ATTACHMENT_DIR - chown -R www-data:www-data /var/www/testrail/config - echo "##############" echo "Waiting for background task file" while [ ! -f /var/www/testrail/task.php ] diff --git a/linux/ecosystem/testrail/ldap/Dockerfile b/linux/ecosystem/testrail/ldap/Dockerfile new file mode 100644 index 000000000..3eca65d54 --- /dev/null +++ b/linux/ecosystem/testrail/ldap/Dockerfile @@ -0,0 +1,15 @@ +FROM epicmorg/testrail:latest + +ARG TESTRAIL_RELEASE_DIR=/testrail-release + +ARG TESTRAIL_PLUGIN_VERSION=1.4 +ARG TESTRAIL_PLUGIN_NAME=ldap +ARG TESTRAIL_PLUGIN_FULLNAME=testrail-auth-${TESTRAIL_PLUGIN_NAME}-${TESTRAIL_PLUGIN_VERSION} +ARG TESTRAIL_PLUGIN_FILE=${TESTRAIL_PLUGIN_FULLNAME}.zip +ARG TESTRAIL_PLUGIN_DONWLOAD_URL=https://media.gurock.com/gk-media/downloads/${TESTRAIL_PLUGIN_FILE} +ARG TESTRAIL_PLUGIN_TEMP=${TESTRAIL_RELEASE_DIR}/${TESTRAIL_PLUGIN_FILE} + +RUN rm -rfv /run.sh +COPY run.sh /run.sh + +RUN wget --no-check-certificate -O ${TESTRAIL_PLUGIN_TEMP} ${TESTRAIL_PLUGIN_DONWLOAD_URL} diff --git a/linux/ecosystem/testrail/ldap/Makefile b/linux/ecosystem/testrail/ldap/Makefile new file mode 100644 index 000000000..bad6d73b5 --- /dev/null +++ b/linux/ecosystem/testrail/ldap/Makefile @@ -0,0 +1,19 @@ +all: app + +app: + make build + make deploy + make clean + +build: + docker-compose build --compress --parallel + +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/testrail/ldap/README.md b/linux/ecosystem/testrail/ldap/README.md new file mode 100644 index 000000000..1aae0e92d --- /dev/null +++ b/linux/ecosystem/testrail/ldap/README.md @@ -0,0 +1,36 @@ +## Testrail + +* Based on `websites:php7.2` of our ecosystem. + +# Compose example + +```yml +version: '3.7' +services: + testrail: + image: epicmorg/testrail +# depends_on: +# - mysql +# - memcached + restart: unless-stopped + volumes: + - /etc/localtime:/etc/localtime + - /etc/timezone:/etc/timezone +# - /etc/letsencrypt:/etc/letsencrypt + - www:/var/www + - apache2:/etc/apache2 + - php:/etc/php + restart: unless-stopped +# extra_hosts: +# - "example.com:192.168.0.11" + tmpfs: + - /tmp + - /var/lib/php/sessions +volumes: + www: + external: true + apache2: + external: true + php: + external: true +``` diff --git a/linux/ecosystem/testrail/ldap/docker-compose.yml b/linux/ecosystem/testrail/ldap/docker-compose.yml new file mode 100644 index 000000000..f3039e286 --- /dev/null +++ b/linux/ecosystem/testrail/ldap/docker-compose.yml @@ -0,0 +1,6 @@ +version: '3.9' +services: + app: + image: "epicmorg/testrail:auth-ldap" + build: + context: . diff --git a/linux/ecosystem/testrail/ldap/run.sh b/linux/ecosystem/testrail/ldap/run.sh new file mode 100755 index 000000000..ea5232745 --- /dev/null +++ b/linux/ecosystem/testrail/ldap/run.sh @@ -0,0 +1,47 @@ +#!/bin/bash +#set -e + +function createOptDirectory { + if [ ! -d $1 ] + then + echo "Creating " $1 + mkdir -p $1 + fi + + chown -R www-data:www-data $1 +} + +/bin/cp -rf /testrail-release/apache-conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf + +echo "##############" +echo "Unzipping testrail" +unzip -o /testrail-release/testrail.zip -d /var/www/ +unzip -o -j /testrail-release/testrail-auth-ldap-1.4.zip testrail-auth-ldap-1.4/auth.php -d ${TR_CUSTOM_AUTH_DIR} && \ +ls -las ${TR_CUSTOM_AUTH_DIR} + +createOptDirectory $TR_DEFAULT_LOG_DIR +createOptDirectory $TR_DEFAULT_AUDIT_DIR +createOptDirectory $TR_DEFAULT_REPORT_DIR +createOptDirectory $TR_DEFAULT_ATTACHMENT_DIR + +chown -R www-data:www-data /var/www/testrail/config + +echo "##############" +echo "Waiting for background task file" +while [ ! -f /var/www/testrail/task.php ] +do + sleep 2 +done + +echo "Starting background task" +while /bin/true; do + php /var/www/testrail/task.php || true + sleep $TR_DEFAULT_TASK_EXECUTION +done & +echo "##############" + +chown www-data:www-data /var/www -R + +source /etc/apache2/envvars +tail -F /var/log/apache2/* & +exec apache2 -D FOREGROUND From 4eab03e0fc71100ef660ee967fa59ec12e99f877 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Tue, 25 Jan 2022 19:28:57 +0300 Subject: [PATCH 17/20] tr optimisations --- linux/ecosystem/testrail/ad/run.sh | 37 +++++++++++++------ linux/ecosystem/testrail/latest/Dockerfile | 14 ++++---- linux/ecosystem/testrail/latest/run.sh | 41 ++++++++++++++++------ linux/ecosystem/testrail/ldap/run.sh | 37 +++++++++++++------ 4 files changed, 90 insertions(+), 39 deletions(-) diff --git a/linux/ecosystem/testrail/ad/run.sh b/linux/ecosystem/testrail/ad/run.sh index f8ce8f0f1..020cbb26c 100755 --- a/linux/ecosystem/testrail/ad/run.sh +++ b/linux/ecosystem/testrail/ad/run.sh @@ -4,7 +4,7 @@ function createOptDirectory { if [ ! -d $1 ] then - echo "Creating " $1 + echo "[testrail] Creating " $1 mkdir -p $1 fi @@ -13,13 +13,11 @@ function createOptDirectory { /bin/cp -rf /testrail-release/apache-conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf -echo "##############" -echo "Unzipping testrail" +echo "[testrail] Unzipping testrail service" unzip -o /testrail-release/testrail.zip -d /var/www/ -unzip -o -j /testrail-release/testrail-auth-ad-1.4.zip testrail-auth-ad-1.4/auth.php -d ${TR_CUSTOM_AUTH_DIR} && \ -ls -las ${TR_CUSTOM_AUTH_DIR} - +echo "[testrail] Unzipping testrail Active Directory auth plugin" +unzip -o -j /testrail-release/testrail-auth-ad-1.4.zip testrail-auth-ad-1.4/auth.php -d ${TR_CUSTOM_AUTH_DIR} createOptDirectory $TR_DEFAULT_LOG_DIR createOptDirectory $TR_DEFAULT_AUDIT_DIR @@ -28,21 +26,38 @@ createOptDirectory $TR_DEFAULT_ATTACHMENT_DIR chown -R www-data:www-data /var/www/testrail/config -echo "##############" -echo "Waiting for background task file" + +################################################################################# + +echo "[testrail] Waiting for background task file" while [ ! -f /var/www/testrail/task.php ] do sleep 2 done -echo "Starting background task" +echo "[testrail] Starting background task" while /bin/true; do php /var/www/testrail/task.php || true sleep $TR_DEFAULT_TASK_EXECUTION done & -echo "##############" +echo "[testrail] Background task stoped" -chown www-data:www-data /var/www -R + +################################################################################# + +if [[ -z "${FIX_WWW_DATA}" ]]; then + echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." +elif [ "${FIX_WWW_DATA}" == "false" ]; then + echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." +elif [ "${FIX_WWW_DATA}" == "true" ]; then + echo "[apache2] Changing permissions for /var/www path. Dont worry, please wait." + chown www-data:www-data /var/www -R + echo "[apache2] Done" +else + echo "[apache2] env FIX_WWW_DATA is set to strange value. Skipping..." +fi + +echo "[apache2] Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & diff --git a/linux/ecosystem/testrail/latest/Dockerfile b/linux/ecosystem/testrail/latest/Dockerfile index f22c012c2..5a16bc0da 100644 --- a/linux/ecosystem/testrail/latest/Dockerfile +++ b/linux/ecosystem/testrail/latest/Dockerfile @@ -1,8 +1,8 @@ FROM epicmorg/apache2:php7.4 -ARG TESTRAIL_VERSION=latest -ARG DOWNLOAD_URL=https://secure.gurock.com/downloads/testrail/testrail-${TESTRAIL_VERSION}-ion72.zip -ARG TESTRAIL_RELEASE_DIR=testrail-release +ENV TESTRAIL_VERSION=latest +ENV DOWNLOAD_URL=https://secure.gurock.com/downloads/testrail/testrail-${TESTRAIL_VERSION}-ion72.zip +ENV TESTRAIL_RELEASE_DIR=/testrail-release ENV TR_DEFAULT_TASK_EXECUTION=60 ENV TR_WWWPATH="/var/www/testrail/" @@ -30,15 +30,15 @@ RUN \ mkdir -p /${TESTRAIL_RELEASE_DIR} && \ mkdir -p /var/www/testrail && \ mkdir -p /opt/testrail/attachments /opt/testrail/reports /opt/testrail/logs /opt/testrail/audit && \ - wget --no-check-certificate -O /${TESTRAIL_RELEASE_DIR}/testrail.zip ${DOWNLOAD_URL} && \ - chown -R www-data:www-data /${TESTRAIL_RELEASE_DIR} && \ - unzip -o /testrail-release/testrail.zip -d /var/www/ && \ + wget --no-check-certificate -O ${TESTRAIL_RELEASE_DIR}/testrail.zip ${DOWNLOAD_URL} && \ + chown -R www-data:www-data ${TESTRAIL_RELEASE_DIR} && \ + unzip -o ${TESTRAIL_RELEASE_DIR}/testrail.zip -d /var/www/ && \ ls -las /var/www/testrail && \ chown -R www-data:www-data /var/www/testrail && \ chown -R www-data:www-data /opt/testrail -COPY apache_testrail.conf /${TESTRAIL_RELEASE_DIR}/apache-conf/000-default.conf +COPY apache_testrail.conf ${TESTRAIL_RELEASE_DIR}/apache-conf/000-default.conf COPY run.sh /run.sh WORKDIR /var/www/testrail diff --git a/linux/ecosystem/testrail/latest/run.sh b/linux/ecosystem/testrail/latest/run.sh index cc5e6118d..85f74d885 100755 --- a/linux/ecosystem/testrail/latest/run.sh +++ b/linux/ecosystem/testrail/latest/run.sh @@ -1,44 +1,63 @@ #!/bin/bash #set -e +#env + +################################################################################## function createOptDirectory { if [ ! -d $1 ] then - echo "Creating " $1 + echo "[testrail] Creating " $1 mkdir -p $1 fi chown -R www-data:www-data $1 } -/bin/cp -rf /testrail-release/apache-conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf +/bin/cp -rf ${TESTRAIL_RELEASE_DIR}/apache-conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf -echo "##############" -echo "Unzipping testrail" -unzip -o /testrail-release/testrail.zip -d /var/www/ +echo "[testrail] Unzipping testrail service" +unzip -o ${TESTRAIL_RELEASE_DIR}/testrail.zip -d /var/www/ createOptDirectory $TR_DEFAULT_LOG_DIR createOptDirectory $TR_DEFAULT_AUDIT_DIR createOptDirectory $TR_DEFAULT_REPORT_DIR createOptDirectory $TR_DEFAULT_ATTACHMENT_DIR -chown -R www-data:www-data /var/www/testrail/config +chown -R www-data:www-data ${TR_CONFIGPATH} -echo "##############" -echo "Waiting for background task file" + +################################################################################# + +echo "[testrail] Waiting for background task file" while [ ! -f /var/www/testrail/task.php ] do sleep 2 done -echo "Starting background task" +echo "[testrail] Starting background task" while /bin/true; do php /var/www/testrail/task.php || true sleep $TR_DEFAULT_TASK_EXECUTION done & -echo "##############" +echo "[testrail] Background task stoped" -chown www-data:www-data /var/www -R + +################################################################################# + +if [[ -z "${FIX_WWW_DATA}" ]]; then + echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." +elif [ "${FIX_WWW_DATA}" == "false" ]; then + echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." +elif [ "${FIX_WWW_DATA}" == "true" ]; then + echo "[apache2] Changing permissions for /var/www path. Dont worry, please wait." + chown www-data:www-data /var/www -R + echo "[apache2] Done" +else + echo "[apache2] env FIX_WWW_DATA is set to strange value. Skipping..." +fi + +echo "[apache2] Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & diff --git a/linux/ecosystem/testrail/ldap/run.sh b/linux/ecosystem/testrail/ldap/run.sh index ea5232745..a3e418e69 100755 --- a/linux/ecosystem/testrail/ldap/run.sh +++ b/linux/ecosystem/testrail/ldap/run.sh @@ -4,7 +4,7 @@ function createOptDirectory { if [ ! -d $1 ] then - echo "Creating " $1 + echo "[testrail] Creating " $1 mkdir -p $1 fi @@ -13,11 +13,11 @@ function createOptDirectory { /bin/cp -rf /testrail-release/apache-conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf -echo "##############" -echo "Unzipping testrail" +echo "[testrail] Unzipping testrail service" unzip -o /testrail-release/testrail.zip -d /var/www/ -unzip -o -j /testrail-release/testrail-auth-ldap-1.4.zip testrail-auth-ldap-1.4/auth.php -d ${TR_CUSTOM_AUTH_DIR} && \ -ls -las ${TR_CUSTOM_AUTH_DIR} + +echo "[testrail] Unzipping testrail LDAP auth plugin" +unzip -o -j /testrail-release/testrail-auth-ldap-1.4.zip testrail-auth-ldap-1.4/auth.php -d ${TR_CUSTOM_AUTH_DIR} createOptDirectory $TR_DEFAULT_LOG_DIR createOptDirectory $TR_DEFAULT_AUDIT_DIR @@ -26,21 +26,38 @@ createOptDirectory $TR_DEFAULT_ATTACHMENT_DIR chown -R www-data:www-data /var/www/testrail/config -echo "##############" -echo "Waiting for background task file" + +################################################################################# + +echo "[testrail] Waiting for background task file" while [ ! -f /var/www/testrail/task.php ] do sleep 2 done -echo "Starting background task" +echo "[testrail] Starting background task" while /bin/true; do php /var/www/testrail/task.php || true sleep $TR_DEFAULT_TASK_EXECUTION done & -echo "##############" +echo "[testrail] Background task stoped" -chown www-data:www-data /var/www -R + +################################################################################# + +if [[ -z "${FIX_WWW_DATA}" ]]; then + echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." +elif [ "${FIX_WWW_DATA}" == "false" ]; then + echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." +elif [ "${FIX_WWW_DATA}" == "true" ]; then + echo "[apache2] Changing permissions for /var/www path. Dont worry, please wait." + chown www-data:www-data /var/www -R + echo "[apache2] Done" +else + echo "[apache2] env FIX_WWW_DATA is set to strange value. Skipping..." +fi + +echo "[apache2] Starting up" source /etc/apache2/envvars tail -F /var/log/apache2/* & From f8eb8462942bca95ab511e97b7839d92bc005682 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Tue, 25 Jan 2022 20:29:02 +0300 Subject: [PATCH 18/20] testrail fixes --- linux/ecosystem/testrail/ad/Dockerfile | 14 ++++---- linux/ecosystem/testrail/ad/run.sh | 21 ++++++------ linux/ecosystem/testrail/latest/Dockerfile | 37 ++++++++++++---------- linux/ecosystem/testrail/latest/run.sh | 12 +++---- linux/ecosystem/testrail/ldap/Dockerfile | 14 ++++---- linux/ecosystem/testrail/ldap/run.sh | 18 +++++------ 6 files changed, 59 insertions(+), 57 deletions(-) diff --git a/linux/ecosystem/testrail/ad/Dockerfile b/linux/ecosystem/testrail/ad/Dockerfile index d302559d6..2d15f799a 100644 --- a/linux/ecosystem/testrail/ad/Dockerfile +++ b/linux/ecosystem/testrail/ad/Dockerfile @@ -1,13 +1,11 @@ FROM epicmorg/testrail:latest -ARG TESTRAIL_RELEASE_DIR=/testrail-release - -ARG TESTRAIL_PLUGIN_VERSION=1.4 -ARG TESTRAIL_PLUGIN_NAME=ad -ARG TESTRAIL_PLUGIN_FULLNAME=testrail-auth-${TESTRAIL_PLUGIN_NAME}-${TESTRAIL_PLUGIN_VERSION} -ARG TESTRAIL_PLUGIN_FILE=${TESTRAIL_PLUGIN_FULLNAME}.zip -ARG TESTRAIL_PLUGIN_DONWLOAD_URL=https://media.gurock.com/gk-media/downloads/${TESTRAIL_PLUGIN_FILE} -ARG TESTRAIL_PLUGIN_TEMP=${TESTRAIL_RELEASE_DIR}/${TESTRAIL_PLUGIN_FILE} +ENV TESTRAIL_PLUGIN_VERSION=1.4 +ENV TESTRAIL_PLUGIN_NAME=ad +ENV TESTRAIL_PLUGIN_FULLNAME=testrail-auth-${TESTRAIL_PLUGIN_NAME}-${TESTRAIL_PLUGIN_VERSION} +ENV TESTRAIL_PLUGIN_FILE=${TESTRAIL_PLUGIN_FULLNAME}.zip +ENV TESTRAIL_PLUGIN_DONWLOAD_URL=https://media.gurock.com/gk-media/downloads/${TESTRAIL_PLUGIN_FILE} +ENV TESTRAIL_PLUGIN_TEMP=${TESTRAIL_RELEASE_DIR}/${TESTRAIL_PLUGIN_FILE} RUN rm -rfv /run.sh COPY run.sh /run.sh diff --git a/linux/ecosystem/testrail/ad/run.sh b/linux/ecosystem/testrail/ad/run.sh index 020cbb26c..5bc9ee463 100755 --- a/linux/ecosystem/testrail/ad/run.sh +++ b/linux/ecosystem/testrail/ad/run.sh @@ -1,5 +1,8 @@ #!/bin/bash #set -e +#env + +################################################################################## function createOptDirectory { if [ ! -d $1 ] @@ -11,20 +14,20 @@ function createOptDirectory { chown -R www-data:www-data $1 } -/bin/cp -rf /testrail-release/apache-conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf +/bin/cp -rf ${TESTRAIL_RELEASE_DIR}/apache-conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf echo "[testrail] Unzipping testrail service" -unzip -o /testrail-release/testrail.zip -d /var/www/ +unzip -o ${TESTRAIL_RELEASE_DIR}/testrail.zip -d /var/www/ echo "[testrail] Unzipping testrail Active Directory auth plugin" -unzip -o -j /testrail-release/testrail-auth-ad-1.4.zip testrail-auth-ad-1.4/auth.php -d ${TR_CUSTOM_AUTH_DIR} +unzip -o -j ${TESTRAIL_RELEASE_DIR}/${TESTRAIL_PLUGIN_FILE} ${TESTRAIL_PLUGIN_FULLNAME}/auth.php -d ${TR_CUSTOM_AUTH_DIR} -createOptDirectory $TR_DEFAULT_LOG_DIR -createOptDirectory $TR_DEFAULT_AUDIT_DIR -createOptDirectory $TR_DEFAULT_REPORT_DIR -createOptDirectory $TR_DEFAULT_ATTACHMENT_DIR +createOptDirectory ${TR_DEFAULT_LOG_DIR} +createOptDirectory ${TR_DEFAULT_AUDIT_DIR} +createOptDirectory ${TR_DEFAULT_REPORT_DIR} +createOptDirectory ${TR_DEFAULT_ATTACHMENT_DIR} -chown -R www-data:www-data /var/www/testrail/config +chown -R www-data:www-data ${TR_CONFIG_DIR} ################################################################################# @@ -38,7 +41,7 @@ done echo "[testrail] Starting background task" while /bin/true; do php /var/www/testrail/task.php || true - sleep $TR_DEFAULT_TASK_EXECUTION + sleep ${TR_DEFAULT_TASK_EXECUTION} done & echo "[testrail] Background task stoped" diff --git a/linux/ecosystem/testrail/latest/Dockerfile b/linux/ecosystem/testrail/latest/Dockerfile index 5a16bc0da..04134ec47 100644 --- a/linux/ecosystem/testrail/latest/Dockerfile +++ b/linux/ecosystem/testrail/latest/Dockerfile @@ -2,19 +2,21 @@ FROM epicmorg/apache2:php7.4 ENV TESTRAIL_VERSION=latest ENV DOWNLOAD_URL=https://secure.gurock.com/downloads/testrail/testrail-${TESTRAIL_VERSION}-ion72.zip +ENV TR_DEFAULT_TASK_EXECUTION=60 + ENV TESTRAIL_RELEASE_DIR=/testrail-release -ENV TR_DEFAULT_TASK_EXECUTION=60 -ENV TR_WWWPATH="/var/www/testrail/" -ENV TR_CONFIGPATH="/var/www/testrail/config/" -ENV TR_CUSTOM_DIR="/var/www/testrail/custom/" -ENV TR_CUSTOM_AUTH_DIR="/var/www/testrail/custom/auth/" +ENV TR_WWW_PATH=/var/www/testrail +ENV TR_CONFIG_DIR=${TR_WWW_PATH}/config +ENV TR_CUSTOM_DIR=${TR_WWW_PATH}/custom +ENV TR_CUSTOM_AUTH_DIR=${TR_CUSTOM_DIR}/auth + +ENV TR_OPT_PATH=/opt/testrail +ENV TR_DEFAULT_LOG_DIR=${TR_OPT_PATH}/logs +ENV TR_DEFAULT_AUDIT_DIR=${TR_OPT_PATH}/audit +ENV TR_DEFAULT_REPORT_DIR=${TR_OPT_PATH}/reports +ENV TR_DEFAULT_ATTACHMENT_DIR=${TR_OPT_PATH}/attachments -ENV TR_OPTPATH="/opt/testrail/" -ENV TR_DEFAULT_LOG_DIR="/opt/testrail/logs/" -ENV TR_DEFAULT_AUDIT_DIR="/opt/testrail/audit/" -ENV TR_DEFAULT_REPORT_DIR="/opt/testrail/reports/" -ENV TR_DEFAULT_ATTACHMENT_DIR="/opt/testrail/attachments/" ENV OPENSSL_CONF=/etc/ssl/ RUN \ @@ -26,16 +28,17 @@ RUN \ RUN \ - echo "WGET" && \ - mkdir -p /${TESTRAIL_RELEASE_DIR} && \ - mkdir -p /var/www/testrail && \ - mkdir -p /opt/testrail/attachments /opt/testrail/reports /opt/testrail/logs /opt/testrail/audit && \ + echo "[testrail] Preparing folders" && \ + mkdir -p ${TESTRAIL_RELEASE_DIR} && \ + mkdir -p ${TR_WWW_PATH} && \ + mkdir -p ${TR_DEFAULT_ATTACHMENT_DIR} ${TR_DEFAULT_REPORT_DIR} ${TR_DEFAULT_AUDIT_DIR} ${TR_DEFAULT_LOG_DIR} && \ + echo "[testrail] Downloading and installing" && \ wget --no-check-certificate -O ${TESTRAIL_RELEASE_DIR}/testrail.zip ${DOWNLOAD_URL} && \ chown -R www-data:www-data ${TESTRAIL_RELEASE_DIR} && \ unzip -o ${TESTRAIL_RELEASE_DIR}/testrail.zip -d /var/www/ && \ - ls -las /var/www/testrail && \ - chown -R www-data:www-data /var/www/testrail && \ - chown -R www-data:www-data /opt/testrail + ls -las ${TR_WWW_PATH} && \ + chown -R www-data:www-data ${TR_WWW_PATH} && \ + chown -R www-data:www-data ${TR_OPT_PATH} COPY apache_testrail.conf ${TESTRAIL_RELEASE_DIR}/apache-conf/000-default.conf diff --git a/linux/ecosystem/testrail/latest/run.sh b/linux/ecosystem/testrail/latest/run.sh index 85f74d885..f1b302fb0 100755 --- a/linux/ecosystem/testrail/latest/run.sh +++ b/linux/ecosystem/testrail/latest/run.sh @@ -19,12 +19,12 @@ function createOptDirectory { echo "[testrail] Unzipping testrail service" unzip -o ${TESTRAIL_RELEASE_DIR}/testrail.zip -d /var/www/ -createOptDirectory $TR_DEFAULT_LOG_DIR -createOptDirectory $TR_DEFAULT_AUDIT_DIR -createOptDirectory $TR_DEFAULT_REPORT_DIR -createOptDirectory $TR_DEFAULT_ATTACHMENT_DIR +createOptDirectory ${TR_DEFAULT_LOG_DIR} +createOptDirectory ${TR_DEFAULT_AUDIT_DIR} +createOptDirectory ${TR_DEFAULT_REPORT_DIR} +createOptDirectory ${TR_DEFAULT_ATTACHMENT_DIR} -chown -R www-data:www-data ${TR_CONFIGPATH} +chown -R www-data:www-data ${TR_CONFIG_DIR} ################################################################################# @@ -38,7 +38,7 @@ done echo "[testrail] Starting background task" while /bin/true; do php /var/www/testrail/task.php || true - sleep $TR_DEFAULT_TASK_EXECUTION + sleep ${TR_DEFAULT_TASK_EXECUTION} done & echo "[testrail] Background task stoped" diff --git a/linux/ecosystem/testrail/ldap/Dockerfile b/linux/ecosystem/testrail/ldap/Dockerfile index 3eca65d54..543fc5aab 100644 --- a/linux/ecosystem/testrail/ldap/Dockerfile +++ b/linux/ecosystem/testrail/ldap/Dockerfile @@ -1,13 +1,11 @@ FROM epicmorg/testrail:latest -ARG TESTRAIL_RELEASE_DIR=/testrail-release - -ARG TESTRAIL_PLUGIN_VERSION=1.4 -ARG TESTRAIL_PLUGIN_NAME=ldap -ARG TESTRAIL_PLUGIN_FULLNAME=testrail-auth-${TESTRAIL_PLUGIN_NAME}-${TESTRAIL_PLUGIN_VERSION} -ARG TESTRAIL_PLUGIN_FILE=${TESTRAIL_PLUGIN_FULLNAME}.zip -ARG TESTRAIL_PLUGIN_DONWLOAD_URL=https://media.gurock.com/gk-media/downloads/${TESTRAIL_PLUGIN_FILE} -ARG TESTRAIL_PLUGIN_TEMP=${TESTRAIL_RELEASE_DIR}/${TESTRAIL_PLUGIN_FILE} +ENV TESTRAIL_PLUGIN_VERSION=1.4 +ENV TESTRAIL_PLUGIN_NAME=ldap +ENV TESTRAIL_PLUGIN_FULLNAME=testrail-auth-${TESTRAIL_PLUGIN_NAME}-${TESTRAIL_PLUGIN_VERSION} +ENV TESTRAIL_PLUGIN_FILE=${TESTRAIL_PLUGIN_FULLNAME}.zip +ENV TESTRAIL_PLUGIN_DONWLOAD_URL=https://media.gurock.com/gk-media/downloads/${TESTRAIL_PLUGIN_FILE} +ENV TESTRAIL_PLUGIN_TEMP=${TESTRAIL_RELEASE_DIR}/${TESTRAIL_PLUGIN_FILE} RUN rm -rfv /run.sh COPY run.sh /run.sh diff --git a/linux/ecosystem/testrail/ldap/run.sh b/linux/ecosystem/testrail/ldap/run.sh index a3e418e69..b4ba56179 100755 --- a/linux/ecosystem/testrail/ldap/run.sh +++ b/linux/ecosystem/testrail/ldap/run.sh @@ -11,20 +11,20 @@ function createOptDirectory { chown -R www-data:www-data $1 } -/bin/cp -rf /testrail-release/apache-conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf +/bin/cp -rf ${TESTRAIL_RELEASE_DIR}/apache-conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf echo "[testrail] Unzipping testrail service" -unzip -o /testrail-release/testrail.zip -d /var/www/ +unzip -o ${TESTRAIL_RELEASE_DIR}/testrail.zip -d /var/www/ echo "[testrail] Unzipping testrail LDAP auth plugin" -unzip -o -j /testrail-release/testrail-auth-ldap-1.4.zip testrail-auth-ldap-1.4/auth.php -d ${TR_CUSTOM_AUTH_DIR} +unzip -o -j ${TESTRAIL_RELEASE_DIR}/${TESTRAIL_PLUGIN_FILE} ${TESTRAIL_PLUGIN_FULLNAME}/auth.php -d ${TR_CUSTOM_AUTH_DIR} -createOptDirectory $TR_DEFAULT_LOG_DIR -createOptDirectory $TR_DEFAULT_AUDIT_DIR -createOptDirectory $TR_DEFAULT_REPORT_DIR -createOptDirectory $TR_DEFAULT_ATTACHMENT_DIR +createOptDirectory ${TR_DEFAULT_LOG_DIR} +createOptDirectory ${TR_DEFAULT_AUDIT_DIR} +createOptDirectory ${TR_DEFAULT_REPORT_DIR} +createOptDirectory ${TR_DEFAULT_ATTACHMENT_DIR} -chown -R www-data:www-data /var/www/testrail/config +chown -R www-data:www-data ${TR_CONFIG_DIR} ################################################################################# @@ -38,7 +38,7 @@ done echo "[testrail] Starting background task" while /bin/true; do php /var/www/testrail/task.php || true - sleep $TR_DEFAULT_TASK_EXECUTION + sleep ${TR_DEFAULT_TASK_EXECUTION} done & echo "[testrail] Background task stoped" From c7542cb968e029d6db4baec84b4941a780551e53 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Tue, 25 Jan 2022 21:05:07 +0300 Subject: [PATCH 19/20] testrail fixes --- linux/ecosystem/testrail/latest/Dockerfile | 9 +++++++-- linux/ecosystem/testrail/latest/run.sh | 4 +++- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/linux/ecosystem/testrail/latest/Dockerfile b/linux/ecosystem/testrail/latest/Dockerfile index 04134ec47..a1776b29a 100644 --- a/linux/ecosystem/testrail/latest/Dockerfile +++ b/linux/ecosystem/testrail/latest/Dockerfile @@ -7,6 +7,7 @@ ENV TR_DEFAULT_TASK_EXECUTION=60 ENV TESTRAIL_RELEASE_DIR=/testrail-release ENV TR_WWW_PATH=/var/www/testrail +ENV TR_CONFIGPATH=${TR_CONFIG_DIR} ENV TR_CONFIG_DIR=${TR_WWW_PATH}/config ENV TR_CUSTOM_DIR=${TR_WWW_PATH}/custom ENV TR_CUSTOM_AUTH_DIR=${TR_CUSTOM_DIR}/auth @@ -17,6 +18,9 @@ ENV TR_DEFAULT_AUDIT_DIR=${TR_OPT_PATH}/audit ENV TR_DEFAULT_REPORT_DIR=${TR_OPT_PATH}/reports ENV TR_DEFAULT_ATTACHMENT_DIR=${TR_OPT_PATH}/attachments +ENV TR_OPTPATH="/opt/testrail/" +ENV TR_CONFIGPATH="/var/www/testrail/config/" + ENV OPENSSL_CONF=/etc/ssl/ RUN \ @@ -36,9 +40,10 @@ RUN \ wget --no-check-certificate -O ${TESTRAIL_RELEASE_DIR}/testrail.zip ${DOWNLOAD_URL} && \ chown -R www-data:www-data ${TESTRAIL_RELEASE_DIR} && \ unzip -o ${TESTRAIL_RELEASE_DIR}/testrail.zip -d /var/www/ && \ - ls -las ${TR_WWW_PATH} && \ chown -R www-data:www-data ${TR_WWW_PATH} && \ - chown -R www-data:www-data ${TR_OPT_PATH} + ls -las ${TR_WWW_PATH} && \ + chown -R www-data:www-data ${TR_OPT_PATH} && \ + ls -las ${TR_OPT_PATH} COPY apache_testrail.conf ${TESTRAIL_RELEASE_DIR}/apache-conf/000-default.conf diff --git a/linux/ecosystem/testrail/latest/run.sh b/linux/ecosystem/testrail/latest/run.sh index f1b302fb0..c1acfe1e4 100755 --- a/linux/ecosystem/testrail/latest/run.sh +++ b/linux/ecosystem/testrail/latest/run.sh @@ -1,4 +1,5 @@ #!/bin/bash + #set -e #env @@ -46,7 +47,8 @@ echo "[testrail] Background task stoped" ################################################################################# if [[ -z "${FIX_WWW_DATA}" ]]; then - echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." + echo "[apache2] env FIX_WWW_DATA is not set. Fixing permissions anyway" + chown www-data:www-data /var/www -R elif [ "${FIX_WWW_DATA}" == "false" ]; then echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." elif [ "${FIX_WWW_DATA}" == "true" ]; then From 500e3e46e06c235f10ba2c779bd8fcf7a9c3c240 Mon Sep 17 00:00:00 2001 From: Anatolii Zimovskii Date: Tue, 25 Jan 2022 21:06:27 +0300 Subject: [PATCH 20/20] testrail fixes --- linux/ecosystem/testrail/ad/run.sh | 3 ++- linux/ecosystem/testrail/ldap/run.sh | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/linux/ecosystem/testrail/ad/run.sh b/linux/ecosystem/testrail/ad/run.sh index 5bc9ee463..36c9a7dbc 100755 --- a/linux/ecosystem/testrail/ad/run.sh +++ b/linux/ecosystem/testrail/ad/run.sh @@ -49,7 +49,8 @@ echo "[testrail] Background task stoped" ################################################################################# if [[ -z "${FIX_WWW_DATA}" ]]; then - echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." + echo "[apache2] env FIX_WWW_DATA is not set. Fixing permissions anyway" + chown www-data:www-data /var/www -R elif [ "${FIX_WWW_DATA}" == "false" ]; then echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." elif [ "${FIX_WWW_DATA}" == "true" ]; then diff --git a/linux/ecosystem/testrail/ldap/run.sh b/linux/ecosystem/testrail/ldap/run.sh index b4ba56179..b09b3ea99 100755 --- a/linux/ecosystem/testrail/ldap/run.sh +++ b/linux/ecosystem/testrail/ldap/run.sh @@ -46,7 +46,8 @@ echo "[testrail] Background task stoped" ################################################################################# if [[ -z "${FIX_WWW_DATA}" ]]; then - echo "[apache2] env FIX_WWW_DATA is not set. Skipping..." + echo "[apache2] env FIX_WWW_DATA is not set. Fixing permissions anyway" + chown www-data:www-data /var/www -R elif [ "${FIX_WWW_DATA}" == "false" ]; then echo "[apache2] env FIX_WWW_DATA is set to false. Skipping..." elif [ "${FIX_WWW_DATA}" == "true" ]; then