jenkins_ci_cd / Dockerfile
Vanos007's picture
jenkins server dockerfile
b44cd98 verified
raw
history blame contribute delete
400 Bytes
# Start from the official Jenkins image
FROM jenkins/jenkins:jdk21
# Switch to the root user to install tools or make any necessary modifications
USER root
# Expose the desired port
EXPOSE 7860
# Set the environment variable for Jenkins to listen on the custom port
ENV JENKINS_OPTS="--httpPort=7860"
# Switch back to the jenkins user
USER jenkins
# Run Jenkins
CMD ["/usr/local/bin/jenkins.sh"]