Skip to content

Commit 0dc0fae

Browse files
committed
Added configuration instructions
1 parent 8e5a74a commit 0dc0fae

File tree

1 file changed

+27
-6
lines changed

1 file changed

+27
-6
lines changed

README.md

Lines changed: 27 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ Serverless SES Forwarder
22
========================
33

44
[![Serverless][ico-serverless]][link-serverless]
5-
[![License](https://img.shields.io/badge/license-MIT-green.svg)][link-license]
65
[![SemVer](http://img.shields.io/:SemVer-1.0.0-brightgreen.svg)](http://semver.org)
6+
[![License](https://img.shields.io/badge/license-MIT-green.svg)][link-license]
77

88
This is a simple, serverless email forwarder that uses [Amazon Simple Email Service (Amazon SES)][link-ses-doc]. It was built using the [Serverless][link-serverless] framework, which is used to create an [Amazon CloudFormation][link-cloudformation] stack that includes most of the necessary assets.
99

@@ -32,10 +32,6 @@ Rename `env.example` to `env.yaml`.
3232

3333
The `env.yaml` file provides the [Amazon SES Rule Set Name][link-ses-rules] that will be used by the [Serverless Framework][link-serverless] to create the Receipt Rule that will forward the email.
3434

35-
It is possible to specify different Rule Set Names for different stages, but
36-
only one Rule Set can be active at a time. It is usually easier to use the same
37-
Rule Set for every stage.
38-
3935
```yaml
4036
# Prod Stage
4137
prod:
@@ -48,6 +44,31 @@ default:
4844
ruleSetName: default-rule-set
4945
```
5046
47+
It is possible to specify different Rule Set Names for different stages, but
48+
only one Rule Set can be active at a time. It is usually easier to use the same
49+
Rule Set for every stage.
50+
51+
#### config.js
52+
53+
Rename `config.example` to `config.js`.
54+
55+
The `config.js` file specifies how emails should be forwarded.
56+
57+
```javascript
58+
module.exports = {
59+
default: {
60+
fromEmail: 'no-reply@verified.domain',
61+
forwardMapping: {
62+
'@sentto.example': [
63+
'address@forwardto.example',
64+
],
65+
},
66+
},
67+
};
68+
```
69+
70+
It is possible to specify different configurations for different stages.
71+
5172
About
5273
-----
5374

@@ -106,7 +127,7 @@ Shout outs to these talented developers:
106127
[ico-serverless]: http://public.serverless.com/badges/v3.svg
107128

108129
[link-cloudformation]: https://aws.amazon.com/cloudformation/
109-
[link-license]: https://github.com/ejsexton82/ses-forwarder/blob/master/LICENSE
130+
[link-license]: https://github.com/ejsexton82/ses-forwarder/blob/master/LICENSE-MIT
110131
[link-serverless]: http://www.serverless.com/
111132
[link-serverless-aws]: https://serverless.com/framework/docs/providers/aws/guide/credentials/
112133
[link-ses]: https://console.aws.amazon.com/ses/home

0 commit comments

Comments
 (0)