Skip to content

Commit

Permalink
Bump up version
Browse files Browse the repository at this point in the history
  • Loading branch information
marcy-terui committed Dec 20, 2016
1 parent 5a31b6d commit f20f3a4
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 59 deletions.
2 changes: 2 additions & 0 deletions .lamvery.test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ configuration:
description: This is sample lambda function.
timeout: 10
memory_size: 128
environment_variables:
FOOENV: bar
# vpc_config:
# subnets:
# - subnet-cadf2993
Expand Down
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 0.18.0
- Official Environment Variables Support
Pass `['Environment']['Variables']` to create/update function from config [#68][] ([@sawanoboly][])

## 0.17.3
- Bugfix [#66][]
- Fix grammer [#65][] ([@ijin][])
Expand Down Expand Up @@ -258,6 +262,8 @@
[#64]: https://github.com/marcy-terui/lamvery/issues/64
[#65]: https://github.com/marcy-terui/lamvery/issues/65
[#66]: https://github.com/marcy-terui/lamvery/issues/66
[#68]: https://github.com/marcy-terui/lamvery/issues/68
[@ijin]: https://github.com/ijin
[@koppeft]: https://github.com/koppeft
[@mathom]: https://github.com/mathom
[@mathom]: https://github.com/mathom
[@sawanoboly]: https://github.com/sawanoboly
61 changes: 5 additions & 56 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ Lamvery
[![Coverage](https://img.shields.io/coveralls/marcy-terui/lamvery.svg)](https://coveralls.io/github/marcy-terui/lamvery)
[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/marcy-terui/lamvery/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/marcy-terui/lamvery/?branch=master)
[![Version](https://img.shields.io/pypi/v/lamvery.svg)](https://pypi.python.org/pypi/lamvery)
[![Downloads](https://img.shields.io/pypi/dm/lamvery.svg)](https://pypi.python.org/pypi/lamvery/)

# Description

Expand Down Expand Up @@ -108,6 +107,8 @@ configuration:
description: This is sample lambda function.
timeout: 10
memory_size: 128
environment_variables:
MYENV: foobar
vpc_config:
subnets:
- subnet-cadf2993
Expand Down Expand Up @@ -155,6 +156,9 @@ The function execution time(seconds) at which Lambda should terminate the functi
- memory_size
The amount of memory for your function environment.

- environment_variables
Environment variables.

- vpc_config
The VPC configurations for the function to access resources in your VPC.
- subnets
Expand Down Expand Up @@ -734,61 +738,6 @@ This is a secret file
END RequestId: 13829c9c-9f13-11e5-921b-6f048cff3c2d
```

# How to use the environment variables in the lambda function

### 1. Write your function
Generate the skeleton function by this command.
```sh
lamvery generate -k function
```

- Python

```py
import lamvery
import os
def lambda_handler(event, context):
lamvery.env.load()
print(os.environ['FOO'])
print(os.environ['BAZ'])
```

- Node.js

```js
var lamvery = require('./lamvery.js');
exports.lambdaHandler = function(event, context) {
lamvery.env.load();
console.log(process.env.FOO);
console.log(process.env.BAZ);
}
```

### 2. Deploy your code with `-e` or `--env` options

```sh
lamvery deploy -e FOO=BAR -e BAZ=QUX
```

### 3. Invoke your function

Command example:
```sh
lamvery invoke {}
```

Result example:
```
START RequestId: 481f2f8a-d64c-11e5-9ebe-4347553b89b4 Version: 25
BAR
QUX
END RequestId: 481f2f8a-d64c-11e5-9ebe-4347553b89b4
```

Development
-----------

Expand Down
2 changes: 1 addition & 1 deletion lamvery/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
Function based deploy and management tool for AWS Lambda.
"""

__version__ = '0.17.3'
__version__ = '0.18.0'

import importlib

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

setup_options = dict(
name='lamvery',
version='0.17.3',
version='0.18.0',
description=description,
long_description=long_description,
author='Masashi Terui',
Expand Down

0 comments on commit f20f3a4

Please sign in to comment.