ops_deploy 0.1.8.3 → 0.1.8.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +30 -0
- data/bin/opsdeploy +2 -0
- data/lib/ops_deploy/cli.rb +7 -0
- data/lib/ops_deploy/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5102cf39c639b4632234d7046c4578fe64f6375e
|
4
|
+
data.tar.gz: 6d3ac1074e8788c01efe04b783f1faa257e1b1f6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cf75ff37b32e8e15922bc1422048c4afd785323fb71d8df15370f5130eeed184d2930e8e92566d2d450a0728b5b40fd8016c9b7060f751fc35b57237155f339b
|
7
|
+
data.tar.gz: 005b51906d84d44dfce7ee01af43a68f1869d475ab3abae2e9ff4f02a5e2252942784af6d6c6e5423e5df0eb5b7a4877dd89b1923106596abeacd20d1a30138f
|
data/README.md
CHANGED
@@ -71,3 +71,33 @@ Output:
|
|
71
71
|
✓ Response from rails-app1: 200 OK
|
72
72
|
// Response check finished
|
73
73
|
```
|
74
|
+
|
75
|
+
If you want to post info about the latest commit to slack:
|
76
|
+
WARNING: This posts the latest commit in the current local git branch, not the latest one on github
|
77
|
+
|
78
|
+
```shell
|
79
|
+
opsdeploy deploy wait check --stack="Example" --aws-region="us-east-1" --post-latest-commit=true
|
80
|
+
```
|
81
|
+
|
82
|
+
Output:
|
83
|
+
|
84
|
+
```
|
85
|
+
-> Getting stack 'Example'...
|
86
|
+
-> Found stack 'Example' (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)
|
87
|
+
-> Latest commit: commit b5fed5c32df0613df06a8e1452d194cafabc22bc
|
88
|
+
Author: Martin Morava <martin.morava@example.com>
|
89
|
+
Date: Tue Aug 9 11:49:56 2016 +0200
|
90
|
+
|
91
|
+
Enable Slack notifications about the latest commit
|
92
|
+
-> Starting deployment on stack 'Example'...
|
93
|
+
✓ Deployment started on stack 'Example'
|
94
|
+
-> Checking deployments...
|
95
|
+
-> Waiting for deployments to finish...
|
96
|
+
..............................................................
|
97
|
+
✓ Deployment OK (58s)
|
98
|
+
// Deployments finished
|
99
|
+
-> Checking instances' HTTP response...
|
100
|
+
.
|
101
|
+
✓ Response from rails-app1: 200 OK
|
102
|
+
// Response check finished
|
103
|
+
```
|
data/bin/opsdeploy
CHANGED
@@ -18,8 +18,10 @@ else
|
|
18
18
|
check_via_proxy = OpsDeploy::CLI.argument('check-via-proxy')
|
19
19
|
wait = OpsDeploy::CLI.argument('wait')
|
20
20
|
wait_via_proxy = OpsDeploy::CLI.argument('wait-via-proxy')
|
21
|
+
post_latest_commit = OpsDeploy::CLI.argument('post-latest-commit')
|
21
22
|
|
22
23
|
cli.start_deployment(stack, app_id, migrate) if deploy
|
24
|
+
cli.post_latest_commit(stack) if post_latest_commit
|
23
25
|
cli.wait_for_deployments(stack, wait_via_proxy) if wait || wait_via_proxy
|
24
26
|
cli.check_instances(stack, check_via_proxy) if check || check_via_proxy
|
25
27
|
end
|
data/lib/ops_deploy/cli.rb
CHANGED
@@ -33,6 +33,13 @@ class OpsDeploy::CLI
|
|
33
33
|
@notification_failure = false
|
34
34
|
end
|
35
35
|
|
36
|
+
def post_latest_commit(stack_id_name_or_object)
|
37
|
+
stack = find_stack(stack_id_name_or_object)
|
38
|
+
latest_commit_description = `git log -1 --pretty=medium`
|
39
|
+
step_msg('Latest commit: ', latest_commit_description)
|
40
|
+
send_notification(stack)
|
41
|
+
end
|
42
|
+
|
36
43
|
def start_deployment(stack_id_name_or_object, application_id = nil, migrate = false)
|
37
44
|
stack = find_stack(stack_id_name_or_object)
|
38
45
|
|
data/lib/ops_deploy/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ops_deploy
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.8.
|
4
|
+
version: 0.1.8.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mahdi Bchetnia
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-08-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk
|