docker-scripts/jira/Dockerfile

42 lines
1.7 KiB
Docker
Raw Normal View History

2018-09-18 13:44:55 +03:00
FROM anapsix/alpine-java:8_jdk
MAINTAINER Atlassian Jira Server Team
ENV RUN_USER daemon
ENV RUN_GROUP daemon
ENV JIRA_HOME /var/atlassian/application-data/jira
ENV JIRA_INSTALL_DIR /opt/atlassian/jira
VOLUME ["${JIRA_HOME}"]
2018-09-18 15:29:01 +03:00
# Expose HTTP port
EXPOSE 8080
2018-09-18 13:44:55 +03:00
WORKDIR $JIRA_HOME
CMD ["/entrypoint.sh", "-fg"]
ENTRYPOINT ["/sbin/tini", "--"]
#RUN apk update -qq \
# && update-ca-certificates \
# && apk add ca-certificates wget curl openssh bash procps openssl perl ttf-dejavu tini libc6-compat \
# && rm -rf /var/lib/{apt,dpkg,cache,log}/ /tmp/* /var/tmp/*
RUN apk update -qq \
&& apk add ca-certificates wget curl openssh bash procps openssl perl ttf-dejavu tini \
&& update-ca-certificates \
&& rm -rf /var/lib/{apt,dpkg,cache,log}/ /tmp/* /var/tmp/*
COPY entrypoint.sh /entrypoint.sh
ARG JIRA_VERSION=7.12.1
ARG DOWNLOAD_URL=http://www.atlassian.com/software/jira/downloads/binary/atlassian-jira-software-${JIRA_VERSION}.tar.gz
COPY . /tmp
RUN mkdir -p ${JIRA_INSTALL_DIR} \
&& curl -L --silent ${DOWNLOAD_URL} | tar -xz --strip-components=1 -C "$JIRA_INSTALL_DIR" \
&& chown -R ${RUN_USER}:${RUN_GROUP} ${JIRA_INSTALL_DIR}/ \
&& sed -i -e 's/-Xms\([0-9]\+[kmg]\) -Xmx\([0-9]\+[kmg]\)/-Xms\${JVM_MINIMUM_MEMORY:=\1} -Xmx\${JVM_MAXIMUM_MEMORY:=\2} \${JVM_SUPPORT_RECOMMENDED_ARGS} -Dconfluence.home=\${JIRA_HOME}/g' ${JIRA_INSTALL_DIR}/bin/setenv.sh \
2018-09-18 15:29:01 +03:00
&& sed -i -e 's/port="8080"/port="8080" secure="${catalinaConnectorSecure}" scheme="${catalinaConnectorScheme}" proxyName="${catalinaConnectorProxyName}" proxyPort="${catalinaConnectorProxyPort}"/' ${JIRA_INSTALL_DIR}/conf/server.xml