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
85649320
Commit
85649320
authored
Jun 18, 2015
by
Fred Smith
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add abbey callbacks
parent
48f867a7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
3 deletions
+15
-3
util/jenkins/build-ami.sh
+8
-2
util/vpc-tools/abbey.py
+7
-1
No files found.
util/jenkins/build-ami.sh
View file @
85649320
...
...
@@ -97,6 +97,13 @@ cleanup_params=""
if
[[
"
$cleanup
"
==
"false"
]]
;
then
cleanup_params
=
"--no-cleanup"
fi
notification_params
=
""
if
[[
!
-z
"
$callback_url
"
]]
;
then
if
[[
!
-z
"
$jobid
"
]]
;
then
notification_params
=
"--callback-url
$callback_url$jobid
"
curl
"
$callback_url$jobid
/starting%20abbey%20for%20
$jobid
"
fi
fi
cd
configuration
pip install
-r
requirements.txt
...
...
@@ -105,5 +112,4 @@ cd util/vpc-tools/
echo
"
$vars
"
>
/var/tmp/
$BUILD_ID
-extra-vars
.yml
cat
/var/tmp/
$BUILD_ID
-extra-vars
.yml
python
-u
abbey.py
-p
$play
-t
c3.large
-d
$deployment
-e
$environment
-i
/edx/var/jenkins/.ssh/id_rsa
$base_params
$blessed_params
$playbookdir_params
--vars
/var/tmp/
$BUILD_ID
-extra-vars
.yml
-c
$BUILD_NUMBER
--configuration-version
$configuration
--configuration-secure-version
$configuration_secure
-k
$jenkins_admin_ec2_key
--configuration-secure-repo
$jenkins_admin_configuration_secure_repo
$configurationprivate_params
$hipchat_params
$cleanup_params
python
-u
abbey.py
-p
$play
-t
c3.large
-d
$deployment
-e
$environment
-i
/edx/var/jenkins/.ssh/id_rsa
$base_params
$blessed_params
$playbookdir_params
--vars
/var/tmp/
$BUILD_ID
-extra-vars
.yml
-c
$BUILD_NUMBER
--configuration-version
$configuration
--configuration-secure-version
$configuration_secure
-k
$jenkins_admin_ec2_key
--configuration-secure-repo
$jenkins_admin_configuration_secure_repo
$configurationprivate_params
$hipchat_params
$cleanup_params
$notification_params
util/vpc-tools/abbey.py
View file @
85649320
...
...
@@ -5,6 +5,7 @@ import time
import
json
import
yaml
import
os
import
requests
try
:
import
boto.ec2
import
boto.sqs
...
...
@@ -124,6 +125,9 @@ def parse_args():
parser
.
add_argument
(
"--hipchat-api-token"
,
required
=
False
,
default
=
None
,
help
=
"The API token for Hipchat integration"
)
parser
.
add_argument
(
"--callback-url"
,
required
=
False
,
default
=
None
,
help
=
"The callback URL to send notifications to"
)
parser
.
add_argument
(
"--root-vol-size"
,
required
=
False
,
default
=
50
,
help
=
"The size of the root volume to use for the "
...
...
@@ -139,7 +143,6 @@ def parse_args():
return
parser
.
parse_args
()
def
get_instance_sec_group
(
vpc_id
):
grp_details
=
ec2
.
get_all_security_groups
(
...
...
@@ -669,6 +672,9 @@ def launch_and_configure(ec2_args):
def
send_hipchat_message
(
message
):
print
(
message
)
if
args
.
callback_url
:
r
=
requests
.
get
(
"{}/{}"
.
format
(
args
.
callback_url
,
message
))
#If hipchat is configured send the details to the specified room
if
args
.
hipchat_api_token
and
args
.
hipchat_room_id
:
import
hipchat
...
...
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