/freenom-workers

Renew your Freenom domain (.cf .ga .gq .ml .tk) automaticly with Cloudflare Workers. 通过Cloudflare Workers自动续期Freenom域名(.cf .ga .gq .ml .tk)。

Primary LanguageJavaScript

IMPORTANT NOTICE

Freenom recently updated their site and added a AWS Captcha, Causing ALL automatic renew sortware to not work. For now, please renew your domain manually. Get updates HERE.

Renew your Freenom domain (.cf .ga .gq .ml .tk) automaticly with Cloudflare Workers.

中文READMEIssuesWikiDiscussions

Like this project? Star it!

Set-up

Open your Cloudflare Dashboard

Select "Workers" in the left sidebar on the homepage.

On the Workers tab,choose "Create a Service",choose your service name,and select a starter (HTTP Handler)。

On the Workers you just created, select "Quick edit".

In the Quick edit interface, copy and paste the code in worker.js and click Save.

Go back to the Workers page you just created and select "Settings" and then "Variables".

On the variables page, add the following variable name and value.

  • SECRET_USERNAME" with your Freenom username.
  • SECRET_PASSWORD" with your Freenom password.

(Optional) Select the Encryption option for both variables to reduce the probability of leakage for your Freenom username and password.

Return to the created Workers page and select Triggers.

On the Trigger screen, click "Add Cron Trigger". On the Add Cron Trigger page, set up the trigger and save the Settings. The recommended execution time is once a day.

On the same interface, Disable the default route (e.g. servicename.subdomain.worker.dev) in Routes.

Test

(Access through Quick edit) Access your deployed Workers service in the Quice edit interface. You should see the remaining dates of all domain names in your account. Please note that access through preview does not trigger renewal. it should only be used for testing purposes.

(Trigger scheduled event) Enter "Quick Edit", select "Set Time", and then select "Trigger scheduled event". You should see the console outputing the remaining date of the domain. (If a renewable domain is detected, the console will output renewal results.)

Showcase

Image

(Successfully renewed on 2022/12/15)

Known Issues

Please check out this Wiki page.

Planned enhancement

Please check out this Wiki page.

Simliar Projects

https://github.com/luolongfei/freenom (PHP)

https://github.com/Oreomeow/freenom-py (Python)

LICENSE

Currently no LICENSE.

mona-loading