Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/luismeyer/pusher
Create Flows that navigate a headless Web-Browser and send Push-Notifications
https://github.com/luismeyer/pusher
automations aws-lambda pupeteer push-notifications
Last synced: 22 days ago
JSON representation
Create Flows that navigate a headless Web-Browser and send Push-Notifications
- Host: GitHub
- URL: https://github.com/luismeyer/pusher
- Owner: luismeyer
- Created: 2023-03-11T21:27:22.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-02-15T20:37:27.000Z (9 months ago)
- Last Synced: 2024-10-04T18:41:26.311Z (about 1 month ago)
- Topics: automations, aws-lambda, pupeteer, push-notifications
- Language: TypeScript
- Homepage: https://phr.vercel.app/
- Size: 1.81 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Pusher 💪
Push-Notifications for everything. Ever wished a Webpage had Push-Notifications? With Pusher you can create Flows that will navigate a Browser through a Website. With a decision tree you can than create messages based on the page content and send them through a push notification channel of your choice.
The Application is available in the Cloud on [phr.vercel.app](https://phr.vercel.app) or you can clone this Repository and host it in you own AWS.
## Development
1. Make sure [direnv](https://direnv.net/) is installed
2. Create a .envrc file based on the .envrc.example file```sh
pnpm install
pnpm run setup
pnpm run dev
```This will start:
- Next Webapp on
- Lambda Invocation Server on
- Lambda HTTP Proxy Endpoint on
- S3 Server on
- DynamoDB Server on## Deployment
Build the App first with `pnpm run build` and
Deploy the AWS Stack:
```sh
pnpm run --filter @pusher/aws deploy
```## Infrastructure
The main parts of the Pusher App are the Runner and the Scheduler AWS Lambda Functions. If you want to host your own Pusher Instance you just need these two Functions. The Scheduler runs on a cron schedule that is defined during the deployment. It reads all Flows out of a DynamoDB Database and Filters the Flows that are not runnable. The Scheduler then invokes the Runner Function providing the Flow as the Payload. The Runner Function executes the Flow by spinning up a Headless Browser and traveling the actionTree.
For the User convinience this Repository also contains an API Lambda Function that exposes Endpoints to interact with the DynamoDB Database and a Webapp that provides a UI to build a Flow JSON Structure and request the API.
Finally this Repository contains a Cleaner Lambda Function that runs once a day to delete old Assets out of the S3 Bucket.