-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
25 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,45 @@ | ||
# cw-logs-to-slack | ||
|
||
This serverless app... TODO | ||
This serverless app publishes AWS CloudWatch logs to Slack based on a subscription filter. | ||
|
||
## App Architecture | ||
|
||
TODO: arch diagram | ||
![App Architecture](https://github.com/keetonian/cw-logs-to-slack/raw/master/images/cw-logs-to-slack.png) | ||
|
||
## Installation Instructions | ||
|
||
1. [Create an AWS account](https://portal.aws.amazon.com/gp/aws/developer/registration/index.html) if you do not already have one and login | ||
1. Go to the app's page on the [Serverless Application Repository](TODO) and click "Deploy" | ||
1. Go to the app's page on the [Serverless Application Repository]() and click "Deploy" | ||
1. Provide the required app parameters (see parameter details below) and click "Deploy" | ||
|
||
### Slack Url | ||
To get a webhook URL for this application: | ||
* Navigate to https://api.slack.com | ||
* Click on the "Start Building" button | ||
* Give your app a name and select a workspace | ||
* Under "Add features and functionality" select "Incoming Webhooks" | ||
* Turn on "Incoming Webhooks" and click "Add New Webhook to Workspace" | ||
* Select the desired channel and click "Authorize" | ||
* Copy the generated Webhook URL | ||
|
||
### Log Group Name | ||
You can find the name of the log group by navigating to CloudWatch logs on the AWS console. You can also pass it in as a parameter from another stack or another resource (e.g. default lambda log group names are `/aws/lambda/{lambda-function-name}`). | ||
|
||
### Filter Pattern | ||
CloudWatch logs allow you to filter logs based on a pattern. For more information, see the [AWS Documentation](https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/FilterAndPatternSyntax.html). | ||
|
||
## App Parameters | ||
|
||
1. `SlackUrl` (required) - Webhook URL for integration with Slack | ||
1. `LogGroupName` (required) - Log group to listen to (has to be in same account and region) | ||
1. `FilterPattern` (optional) - Pattern for filtering log events. Default: ERROR | ||
1. `LogLevel` (optional) - Log level for Lambda function logging, e.g., ERROR, INFO, DEBUG, etc. Default: INFO | ||
1. ... | ||
|
||
## App Outputs | ||
|
||
1. `MyFunctionName` - My Lambda function name. | ||
1. ... | ||
1. `LogsToSlackName` - Lambda function name. | ||
1. `LogsToSlackArn` - Lambda function ARN. | ||
|
||
## License Summary | ||
|
||
This code is made available under the TODO license. See the LICENSE file. | ||
This code is made available under the MIT license. See the LICENSE file. |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.