项目作者: ngocphamm

项目描述 :
Check and report public IP change via email.
高级语言: PHP
项目地址: git://github.com/ngocphamm/ipchange-reporter.git
创建时间: 2016-01-14T02:47:46Z
项目社区:https://github.com/ngocphamm/ipchange-reporter

开源协议:MIT License

下载


Check your public IP address (via default https://icanhazip.com but feel free to change to whatever service you want), and update a DNS record of your choice, in CloudFlare, and send an email notification, with Mailgun.

It is checked every 15 minutes, but only logged to the database (SQLite) once every hour. The cron can be changed to whatever supported by Alpine. Can also check out this FAQ.

.env file should look like below with the data pieces for CloudFlare and Mailgun.

  1. TZ=America/New_York
  2. DATA_FOLDER_BASEPATH=/path/to/persistent/data/folder
  3. CLOUDFLARE_API_TOKEN=''
  4. CLOUDFLARE_EMAIL=''
  5. CLOUDFLARE_ZONE_ID=''
  6. CLOUDFLARE_DOMAIN_ID=''
  7. CLOUDFLARE_DOMAIN_NAME=''
  8. MAILGUN_API_KEY=''
  9. MAILGUN_DOMAIN=''
  10. REPORT_FROM_EMAIL=''
  11. REPORT_TO_EMAIL=''

Optionally, you can also have Litestream service to replicate the SQLite database to an AWS S3 bucket of your choice. When that is needed, uncomment out the litestream service in docker-compose.yml file, and add the following to .env file.

  1. LITESTREAM_ACCESS_KEY_ID=''
  2. LITESTREAM_SECRET_ACCESS_KEY=''
  3. LITESTREAM_S3_BUCKET_NAME=''