Class: Lono::Cfn::Help

Inherits:
Object
  • Object
show all
Defined in:
lib/lono/cfn/help.rb

Class Method Summary collapse

Class Method Details

.createObject



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
28
# File 'lib/lono/cfn/help.rb', line 3

def create
"Examples:\n\nProvided that you are in a lono project and have a `my-stack` lono template definition.  To create a stack you can simply run:\n\n$ lono cfn create my-stack\n\nThe above command will generate and use the template in output/my-stack.json and parameters in params/my-stack.txt.  The template by convention defaults to the name of the stack.  In turn, the params by convention defaults to the name of the template.\n\nHere are examples of overriding the template and params name conventions.\n\n$ lono cfn create my-stack --template different1\n\nThe template used is output/different1.json and the parameters used is output/params/prod/different1.json.\n\n$ lono cfn create my-stack --params different2\n\nThe template used is output/my-stack.json and the parameters used is output/params/prod/different2.json.\n\n$ lono cfn create my-stack --template different3 --params different4\n\nThe template used is output/different3.json and the parameters used is output/params/prod/different4.json.\n\n"
end

.deleteObject



57
58
59
60
61
62
63
64
65
# File 'lib/lono/cfn/help.rb', line 57

def delete
"Examples:\n\n$ lono cfn delete my-stack\n\nThe above command will delete my-stack.\n"
end

.diffObject



83
84
85
86
87
88
89
90
91
# File 'lib/lono/cfn/help.rb', line 83

def diff
"Displays code diff of the generated CloudFormation template locally vs the existing template on AWS. You can set a desired diff viewer by setting the LONO_CFN_DIFF environment variable.\n\nExamples:\n\n$ lono cfn diff my-stack\n"
end

.downloadObject



93
94
95
96
97
98
99
100
101
# File 'lib/lono/cfn/help.rb', line 93

def download
"Download CloudFormation template from existing template on AWS.\n\nExamples:\n\n$ lono cfn download my-stack\n"
end

.previewObject



67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
# File 'lib/lono/cfn/help.rb', line 67

def preview
"Generates a CloudFormation preview.  This is similar to a `terraform plan` or puppet's dry-run mode.\n\nExample output:\n\nCloudFormation preview for 'example' stack update. Changes:\n\nRemove AWS::Route53::RecordSet: DnsRecord testsubdomain.sub.tongueroo.com\n\nExamples:\n\n$ lono cfn preview my-stack\n"
end

.updateObject



30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# File 'lib/lono/cfn/help.rb', line 30

def update
"Examples:\n\nProvided that you are in a lono project and have a `my-stack` lono template definition.  To update a stack you can simply run:\n\n$ lono cfn update my-stack\n\nThe above command will generate and use the template in output/my-stack.json and parameters in params/my-stack.txt.  The template by convention defaults to the name of the stack.  In turn, the params by convention defaults to the name of the template.\n\nHere are examples of overriding the template and params name conventions.\n\n$ lono cfn update my-stack --template different1\n\nThe template used is output/different1.json and the parameters used is output/params/prod/different1.json.\n\n$ lono cfn update my-stack --params different2\n\nThe template used is output/my-stack.json and the parameters used is output/params/prod/different2.json.\n\n$ lono cfn update my-stack --template different3 --params different4\n\nThe template used is output/different3.json and the parameters used is output/params/prod/different4.json.\n\n"
end