debian.ansible.dedyn.client/README.md

63 lines
1.8 KiB
Markdown
Raw Normal View History

2023-08-21 16:01:07 +02:00
# DynDNS with dedyn/deSEC (https://desec.io)
2023-08-23 16:07:27 +02:00
This is needed if you want to make services available from the Internet from a changing (dynamic) IP (widely used for private intrnet connections). This may also be needed to validate SSL-ACME-Challenges used by letsencrypt.
2023-08-23 13:29:07 +02:00
deSEC is my preferred DNS provider but there are others too.
2023-08-21 16:01:07 +02:00
# Disclaimer
Use at your own risk.
Please look first at the playbooks downloaded and run by the install.sh to understand whats going on and then decide if it is fine for you to run on your system.
You also should test this on an non-productive Test-System to fit your needs.
2023-08-23 13:29:07 +02:00
# Quick-Install
2023-08-23 13:38:47 +02:00
## 1. Register on the https://desec.io/ website
2023-08-23 13:29:07 +02:00
2023-08-23 13:38:47 +02:00
## 2. Create a domain - Click on + in https://desec.io/domains
2023-08-23 13:29:07 +02:00
2023-08-23 13:38:47 +02:00
## 3. Create a CNAME wildcard for your domain
2023-08-23 13:29:07 +02:00
- click on your domain
- click on "+"
- Record Set Type: CNAME
- Subname: *
- Target hostname: choosen-domainname.dedyn.io. (finalizing "." is important)
- click on "Save"
2023-08-23 13:38:47 +02:00
## 4. Get an auth Token
2023-08-23 13:39:33 +02:00
- click on "Token Management"
2023-08-23 13:38:47 +02:00
- click on "+"
- optinally give a name
- click on "Save"
- copy your "token's secret value"
## 5. SSH into your Server and write the config customized with your data:
2023-08-23 13:29:07 +02:00
```
2023-08-23 13:38:47 +02:00
echo 'dedynpw="TOKENS_SECRET_VALUE_FROM_DESEC"
2023-08-23 13:29:07 +02:00
dedynhosts="choosen-domainname.dedyn.io"
# should IPv6 be done? possible are "yes", "no" or "only"
doipv6="yes"' >/usr/local/etc/dedyn.conf
```
2023-08-23 13:38:47 +02:00
## 6. Download
2023-08-23 13:29:07 +02:00
```
2023-08-23 14:40:17 +02:00
wget https://gitea.ds9.dedyn.io/olli/debian.ansible.basics/raw/branch/main/install.sh
2023-08-23 13:29:07 +02:00
```
2023-08-23 13:38:47 +02:00
## 7. Run the Script
2023-08-23 13:29:07 +02:00
This runs some other Playbooks needed by this playbook.
```
2023-08-23 14:40:17 +02:00
export PLAYBOOKS="
debian.ansible.basics
debian.ansible.runchecks
debian.ansible.autoupdate
debian.ansible.dedyn.client
"
2023-08-23 13:29:07 +02:00
bash install.sh
```
2023-08-23 13:38:47 +02:00
# After the Installation
- When changing IP, the address should update every half hour
- you can manually update with ```sudo dedyn.sh```