mirror of
https://github.com/jung-geun/DynamicDNS-SSL.git
synced 2025-12-19 20:44:40 +09:00
2.9 KiB
2.9 KiB
DynamicDNS-SSL
DynamicDNS-SSL is a script that automatically performs dynamic DNS updates (DDNS) through Cloudflare and automatically renews SSL certificates using Certbot. This project helps domain owners manage their DNS and SSL certificates automatically without the need for manual updates whenever the IP address changes.
This project is useful for individuals using dynamic IPs or small-scale server operators.
Key Features
- Automatic DNS Updates: Automatically updates DNS records using the Cloudflare API whenever the IP address changes.
- Automatic SSL Certificate Renewal: Automatically issues and renews SSL certificates using Certbot.
- Configuration File Usage: Easily change settings through a JSON configuration file.
Requirements
Before getting started, ensure you have the following:
- Cloudflare account
- Registered domain name
- Cloudflare API credentials
Installation
1. Clone the Project
git clone https://github.com/jung-geun/cloudflare-ddns.git
<!-- or -->
git clone https://git.pieroot.xyz/jung-geun/cloudflare-ddns.git
cd cloudflare-ddns
2. Install Required Packages
sudo apt update
sudo apt install -y certbot python3-certbot-dns-cloudflare jq
<!-- or -->
make install # You can use the Makefile to install packages.
3. Create Configuration File
vi /app/cloudflare-ddns/config/env.json
Write the configuration file as follows:
{
"CLOUDFLARE_API_KEY": "your_cloudflare_api_key",
"CLOUDFLARE_ZONE_ID": "your_cloudflare_zone_id",
"CLOUDFLARE_DOMAIN": "example.com",
"EMAIL": "your_email@example.com",
"CLOUDFLARE_A": {
"@": true
},
"CLOUDFLARE_CNAME": {
"@": {
"www": true
}
},
"CLOUDFLARE_MX": {}
}
Contribution
Contributions are welcome! If you have any suggestions or improvements, please open an issue or submit a pull request.
License
This project is licensed under the MIT License. See the LICENSE file for more information.