Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
configuration
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
configuration
Commits
01e6def7
Commit
01e6def7
authored
Sep 18, 2013
by
Will Daly
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use upstart script to create Jenkins workspace on /mnt
parent
01503e09
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
8 deletions
+24
-8
playbooks/roles/jenkins_worker/tasks/system.yml
+13
-7
playbooks/roles/jenkins_worker/templates/jenkins_workspace.conf.j2
+10
-0
playbooks/roles/jenkins_worker/vars/main.yml
+1
-1
No files found.
playbooks/roles/jenkins_worker/tasks/system.yml
View file @
01e6def7
...
...
@@ -9,19 +9,24 @@
shell
:
touch {{ jenkins_user_home }}/.bashrc
sudo_user
:
"
{{
jenkins_user
}}"
-
name
:
jenkins | Create directory for builds
file
:
path={{ jenkins_workspace }}
owner={{ jenkins_user }} group={{ jenkins_group }}
state=directory
-
name
:
jenkins | Create .ssh directory
file
:
path={{ jenkins_user_home }}/.ssh state=directory
owner={{ jenkins_user }} group={{ jenkins_group }}
# We need the upstart script to create the build directory
# so that (a) it will be run when a new instance is created
# on the current EBS, and (b) it will be run as root.
-
name
:
jenkins | Install upstart script to create build dir
template
:
src=jenkins_workspace.conf.j2
dest=/etc/init/jenkins_workspace.conf
owner=root group=root
# Because of a bug in the latest release of the EC2 plugin
# we need to use a key generated by Amazon (not imported)
# To satisfy this, we allow users to log in as Jenkins
# using the same keypair the instance was started with.
-
name
:
jenkins | Create .ssh directory
file
:
path={{ jenkins_user_home }}/.ssh state=directory
owner={{ jenkins_user }} group={{ jenkins_group }}
-
name
:
jenkins | Copy ssh keys for jenkins
command
:
cp /home/ubuntu/.ssh/authorized_keys /home/{{ jenkins_user }}/.ssh/authorized_keys
...
...
@@ -49,6 +54,7 @@
-
unzip
-
xml-twig-tools
# Configure Mongo to use /mnt so we don't
# run out of disk space
-
name
:
jenkins | Stop mongo service
...
...
playbooks/roles/jenkins_worker/templates/jenkins_workspace.conf.j2
0 → 100644
View file @
01e6def7
# Create directory for Jenkins jobs
start on runlevel [2345]
task
script
mkdir -p {{ jenkins_workspace }}
chown {{ jenkins_user }}:{{ jenkins_group }} {{ jenkins_workspace }}
chmod 700 {{ jenkins_workspace }}
end script
playbooks/roles/jenkins_worker/vars/main.yml
View file @
01e6def7
---
jenkins_workspace
:
/
op
t/jenkins
jenkins_workspace
:
/
mn
t/jenkins
jenkins_phantomjs_url
:
https://phantomjs.googlecode.com/files/phantomjs-1.9.1-linux-x86_64.tar.bz2
jenkins_phantomjs_archive
:
phantomjs-1.9.1-linux-x86_64.tar.bz2
jenkins_phantomjs_folder
:
phantomjs-1.9.1-linux-x86_64
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment