Service to send push notifications through sygnal matrix API for encrypted device info.
Env variables
Required:
to start use docker-compose file.
docker-compose up -d
SERVER_HOST - public URL to polygon push gateway. REDIS_URL - URL to Redis instance. Redis is used for temporary cache of schemas. GATEWAY_HOST - URL to sygnal matrix instance PRIVATE_KEY - Encryption key.
Not required:
SERVER_PORT - port to run pgg on. Default: 8085. LOG_LEVEL - log level. Default debug. LOG_ENV - log env. Default development.
apps - list of apps. You can add more apps. apps.polygon.web - is name of app. You can change it to any name. apps.app_name.type - type of app. You can use gcm or fcm for android devices. apps.app_name.api_key - api key for push notifications. You can get it from firebase console. apps.app_name.fcm_options.content_available - enable/disable content in a notification message. apps.app_name.fcm_options.mutable_content - enables the service extension on the receiving client to handle the image delivered in the payload.
Run docker compose:
docker-compose up -d
Test
Run the send_notification.sh script and pass the device token as the first parameter: