forked from AndreyMaximov/docker-jenkins-nginx-letsencrypt
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathinstall.sh
More file actions
executable file
·28 lines (21 loc) · 835 Bytes
/
install.sh
File metadata and controls
executable file
·28 lines (21 loc) · 835 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/usr/bin/env bash
# Provisions Jenkins
VIRTUAL_HOST=${VIRTUAL_HOST:-localhost}
# Clean up.
docker-compose rm -s -f
rm -rf jenkins_home
# Copy jobs definition.
cp -r jenkins_template jenkins_home
chmod +x jenkins_home/install_plugins.sh
sed -i "s/localhost/${VIRTUAL_HOST}/" jenkins_home/nodes/Worker/config.xml
# Get the NGINX, Jenkins and Puppeteer up.
docker-compose up -d
# Install Jenkins plugins.
docker-compose exec jenkins bash -c "~/install_plugins.sh"
# Guide users with the following configuration.
echo ''
echo "###################################################################"
echo "# Use this password to proceed with the configuration: #"
PASSWORD=$(cat jenkins_home/secrets/initialAdminPassword)
echo "# ${PASSWORD}"
echo "###################################################################"