@@ -27,29 +27,36 @@ Configuration File
27
27
~~~~~~~~~~~~~~~~~~
28
28
29
29
The lambda uploader expects a directory with, at a minimum, your lambda
30
- function and a lambda.json file. It is not necessary to set requirements
31
- in your config file since the lambda uploader will also check for and
32
- use a requirements.txt file.
30
+ function and a `` lambda.json `` file. It is not necessary to set
31
+ requirements in your config file since the lambda uploader will also
32
+ check for and use a requirements.txt file.
33
33
34
- Please note that you can leave the "vpc" object out of your config if you want your
35
- lambda function to use your default VPC and subnets. If you wish to use your lambda
36
- function inside a specific VPC, make sure you set up the role correctly to allow this.
34
+ Please note that you can leave the ``vpc `` object out of your config if
35
+ you want your lambda function to use your default VPC and subnets. If
36
+ you wish to use your lambda function inside a specific VPC, make sure
37
+ you set up the role correctly to allow this.
37
38
38
- Example lambda.json file:
39
+ Note also the ``ignore `` entry is an array of regular expression strings
40
+ used to match against the relative paths - be careful to quote
41
+ accordingly. For example, a traditional ``*.txt `` "glob" is matched by
42
+ the JSON string: ``".*\\.txt$" `` (or just ``"\\.txt$" ``).
43
+
44
+ Example ``lambda.json `` file:
39
45
40
46
.. code :: json
41
47
42
48
{
43
49
"name" : " myFunction" ,
44
50
"description" : " It does things" ,
45
51
"region" : " us-east-1" ,
52
+ "runtime" : " python2.7" ,
46
53
"handler" : " function.lambda_handler" ,
47
54
"role" : " arn:aws:iam::00000000000:role/lambda_basic_execution" ,
48
55
"requirements" : [" pygithub" ],
49
56
"ignore" : [
50
- " circle.yml" ,
51
- " .git" ,
52
- " /* .pyc"
57
+ " circle\\ .yml$ " ,
58
+ " \\ .git$ " ,
59
+ " /.* \\ .pyc$ "
53
60
],
54
61
"timeout" : 30 ,
55
62
"memory" : 512 ,
@@ -93,7 +100,8 @@ To omit using a virtualenv use the ``--no-virtualenv`` parameter.
93
100
94
101
lambda-uploader --no-virtualenv
95
102
96
- To inject any other additional files, use the ``--extra-file EXTRA_FILE `` parameter.
103
+ To inject any other additional files, use the
104
+ ``--extra-file EXTRA_FILE `` parameter.
97
105
98
106
.. code :: shell
99
107
@@ -121,3 +129,11 @@ alias-description is not provided.
121
129
.. code :: shell
122
130
123
131
lambda-uploader --alias myAlias --alias-description ' My alias description' ./myfunc
132
+
133
+ If you would prefer to build the package manually and just upload it
134
+ using uploader you can ignore the build. This will upload
135
+ ``lambda_function.zip `` file.
136
+
137
+ .. code :: shell
138
+
139
+ lambda-uploader --no-build
0 commit comments