lamby 0.5.0 → 0.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8013b19c9361fe4a34b96607930c8591e805db0cc22e22a2c490cb95ea711ca7
4
- data.tar.gz: 89ee1f0256188b82ae65f827c036d75373cb68196a90f32a478e512c31a94a8f
3
+ metadata.gz: fcbbfe7eddb8acad415555fea80e62f2bd9e7dd265e2c48ec5921e9f97f1e436
4
+ data.tar.gz: 5c27a927c94e8e49117f384cf17e657be0f75c570fe4d162111ed9775cf66e16
5
5
  SHA512:
6
- metadata.gz: 6da7008851be7f91d0e967434ef963e7d5d41c006122f4a8801cb8b3217d0504a7a2fcf97d55c4c83aad0f83914a4bb158628be5b749afdf1969e8e3fbd407fc
7
- data.tar.gz: 1d81577d4640c7fa95b4f32e8aa40600607ac8aa87e395adc2e3c35d049260e2a829d2b77e9321988c77e756b8d7b5c003e93b6cacc4bbedb55ff37f9a59b47a
6
+ metadata.gz: 2a251f3fc0441f08fc8dbcb12a52aef07b10c200fa27728406d53fdc2a15df8dfc5c711fd5c37c313e7ad2663b82c6d481cfe25883c344dff5713b63628b9072
7
+ data.tar.gz: 40ceda09d0393eadc9e457d3c4f55c9c3812c366f9b63185846be31d848a288139a37f0adecd694f153a683842d60c2d47a8e9511c6cb1dce685469000d84308
data/CHANGELOG.md CHANGED
@@ -2,6 +2,14 @@
2
2
 
3
3
  See this http://keepachangelog.com link for information on how we want this documented formatted.
4
4
 
5
+
6
+ ## v0.5.1
7
+
8
+ #### Fixed
9
+
10
+ * The .gitignore file template. Fix .aws-sam dir.
11
+
12
+
5
13
  ## v0.5.0
6
14
 
7
15
  #### Added
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- lamby (0.5.0)
4
+ lamby (0.5.1)
5
5
  rack
6
6
  rails
7
7
 
data/README.md CHANGED
@@ -89,7 +89,7 @@ aws s3 mb "s3://lamby.cloudformation.$(whoami)"
89
89
 
90
90
  #### Configuration
91
91
 
92
- We recommend using [Rails Credentials](https://guides.rubyonrails.org/security.html#environmental-security) by setting the `RAILS_MASTER_KEY` environment variable in your `app.rb` file. The value be read from AWS Systems Manager [Parameter Store](https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-paramstore.html) which Lamby has a client wrapper for. To set that value, use the following AWS CLI command.
92
+ We recommend getting started using [Rails Credentials](https://guides.rubyonrails.org/security.html#environmental-security) by setting the `RAILS_MASTER_KEY` environment variable in your `app.rb` file. The value be read from AWS Systems Manager [Parameter Store](https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-paramstore.html) which Lamby has a client wrapper for. To set the master key value, use the following AWS CLI command.
93
93
 
94
94
  ```shell
95
95
  aws ssm put-parameter \
@@ -105,6 +105,22 @@ ENV['RAILS_MASTER_KEY'] =
105
105
  Lamby::SsmParameterStore.get!('/config/my_awesome_lambda/env/RAILS_MASTER_KEY')
106
106
  ```
107
107
 
108
+ Finally, updated your `template.yaml` CloudFormation/SAM file by adding this to the `Properties` section of your `RailsFunction`. This addition allows your Lambda's runtime policy to read configs from SSM Parameter store.
109
+
110
+ ```yaml
111
+ Policies:
112
+ - Version: "2012-10-17"
113
+ Statement:
114
+ - Effect: Allow
115
+ Action:
116
+ - ssm:GetParameter
117
+ - ssm:GetParameters
118
+ - ssm:GetParametersByPath
119
+ - ssm:GetParameterHistory
120
+ Resource:
121
+ - !Sub arn:aws:ssm:${AWS::Region}:${AWS::AccountId}:parameter/config/my_awesome_lambda/*
122
+ ```
123
+
108
124
  #### First Deploy!
109
125
 
110
126
  Now your Rails app is ready to be deployed to AWS Lambda via CloudFormation & SAM.
@@ -113,6 +129,15 @@ Now your Rails app is ready to be deployed to AWS Lambda via CloudFormation & SA
113
129
  $ ./bin/deploy
114
130
  ```
115
131
 
132
+ To see your newly created Lambda's API Gateway URL, log into the AWS Console or run the following command. This will describe the CloudFormation stack we just deployed and the `Outputs` from that template.
133
+
134
+ ```shell
135
+ aws cloudformation describe-stacks \
136
+ --stack-name "awesomebotlambda-production-us-east-1" | \
137
+ grep OutputValue | \
138
+ grep https
139
+ ```
140
+
116
141
 
117
142
  ## Additional Documentation
118
143
 
@@ -12,7 +12,7 @@ say 'Adding to .gitignore...'
12
12
  FileUtils.touch app_file('.gitignore')
13
13
  append_to_file app_file('.gitignore'), <<-GITIGNORE.strip_heredoc
14
14
  # Lamby
15
- '/.aws-sam'
15
+ /.aws-sam
16
16
  GITIGNORE
17
17
 
18
18
  say 'Creating ./bin files for build and deploy...'
data/lib/lamby/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Lamby
2
- VERSION = '0.5.0'
2
+ VERSION = '0.5.1'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lamby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ken Collins