You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[AWS CLI](https://aws.amazon.com/cli/) - sammie uses this for all AWS operations under the hood.
16
16
17
17
### Quickstart
18
18
@@ -22,11 +22,11 @@ sammie init my-app
22
22
sammie deploy
23
23
```
24
24
25
-
This will initialize a basic SAM template, deploy it to a development environment, and direct you to your app served over https!
25
+
This will generate a basic serverless application, deploy it to a development environment, and direct you to your app served over https!
26
26
27
27
### Commands
28
28
29
-
#### init - Generates a SAM template & lambda function
29
+
#### init - Generates a serverless application including a SAM template & lambda function
30
30
31
31
`sammie init <name>`
32
32
_Options:_
@@ -40,20 +40,34 @@ _Options:_
40
40
`-e, --environment`: An environment name to deploy. Defaults to "development".
41
41
`-p, --parameters`: A list of parameters to override in your template.
42
42
43
-
### Bootstrapping existing SAM projects
43
+
### Environments
44
44
45
-
If you already have a SAM template, you can use `sammie deploy` for a simplified deployment.
46
-
Make sure to add the following parameters to your template so sammie knows where to deploy:
45
+
It's a best practice to create completely separate stacks for each of your application's environments, rather than a single stack with multiple lambda qualifiers, API Gateway stages, and permissions. This makes your application more portable and reduces the blast radius of taking down your live application during the development cycle.
46
+
47
+
To support this, sammie will deploy separate stacks for you based on your environment option.
48
+
E.g. your stack name is "my-app":
49
+
`sammie deploy` will deploy stack "my-app-development"
50
+
`sammie deploy --environment production` will deploy stack "my-app-production"
51
+
52
+
#### Environment variables & properties
53
+
54
+
To add environemnt specific variables & properties, you can create separate sam templates named with the environemnt suffix.
55
+
E.g. `sam-production.json` containing the following, will get merged with your base template `sam.json` upon `sammie deploy --environment production`
0 commit comments