feat(jenkins): add Jenkins CI/CD Platform Cloudron package
- Complete Jenkins package with Java 17 and WAR file download - Proper CloudronManifest.json with correct metadata - Custom start.sh script with Jenkins configuration - Health check endpoint configured for /login - Follows KNELCloudron- naming convention - Added comprehensive packaging shortlist with 56 applications prioritized by phase
This commit is contained in:
50
CloudronPackages/Jenkins/Dockerfile
Normal file
50
CloudronPackages/Jenkins/Dockerfile
Normal file
@@ -0,0 +1,50 @@
|
||||
FROM cloudron/base:5.0.0
|
||||
|
||||
# Metadata labels
|
||||
LABEL org.opencontainers.image.title="Jenkins CI/CD"
|
||||
LABEL org.opencontainers.image.description="Cloudron package for Jenkins CI/CD Platform"
|
||||
LABEL org.opencontainers.image.source="https://github.com/jenkinsci/jenkins"
|
||||
|
||||
# Install Java and Jenkins dependencies
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
openjdk-17-jdk \
|
||||
curl \
|
||||
ca-certificates \
|
||||
git \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Set Java environment
|
||||
ENV JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64
|
||||
ENV PATH=$JAVA_HOME/bin:$PATH
|
||||
|
||||
# Create Jenkins directories
|
||||
RUN mkdir -p /app/data/jenkins_home && \
|
||||
mkdir -p /app/data/plugins && \
|
||||
mkdir -p /app/pkg && \
|
||||
chown -R cloudron:cloudron /app/data
|
||||
|
||||
# Download and install Jenkins WAR file
|
||||
ARG JENKINS_VERSION=2.450
|
||||
RUN cd /tmp && \
|
||||
curl -fsSL "https://get.jenkins.io/war/${JENKINS_VERSION}/jenkins.war" -o jenkins.war && \
|
||||
mv jenkins.war /app/pkg/jenkins.war && \
|
||||
chown cloudron:cloudron /app/pkg/jenkins.war
|
||||
|
||||
# Copy startup script
|
||||
COPY start.sh /app/pkg/start.sh
|
||||
RUN chmod +x /app/pkg/start.sh && chown cloudron:cloudron /app/pkg/start.sh
|
||||
|
||||
USER cloudron
|
||||
|
||||
# Expose Jenkins port
|
||||
EXPOSE 8080
|
||||
|
||||
# Jenkins environment variables
|
||||
ENV JENKINS_HOME=/app/data/jenkins_home \
|
||||
JENKINS_OPTS="--httpPort=8080 --httpListenAddress=0.0.0.0" \
|
||||
APP_PORT=8080
|
||||
|
||||
HEALTHCHECK --interval=30s --timeout=10s --start-period=60s --retries=3 \
|
||||
CMD curl -fsS http://127.0.0.1:${APP_PORT}/login || exit 1
|
||||
|
||||
CMD ["/app/pkg/start.sh"]
|
Reference in New Issue
Block a user