Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/stevenweathers/google-domains-ddns-updater
App to update GoogleDomains Dynamic DNS with local WAN IP
https://github.com/stevenweathers/google-domains-ddns-updater
ddns ddns-updater dynamic-dns google-domains-ip-updater googledomains-dynamic-dns
Last synced: about 1 month ago
JSON representation
App to update GoogleDomains Dynamic DNS with local WAN IP
- Host: GitHub
- URL: https://github.com/stevenweathers/google-domains-ddns-updater
- Owner: StevenWeathers
- License: mit
- Created: 2018-12-07T04:13:49.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2023-10-07T13:33:18.000Z (about 1 year ago)
- Last Synced: 2024-05-01T19:37:52.479Z (8 months ago)
- Topics: ddns, ddns-updater, dynamic-dns, google-domains-ip-updater, googledomains-dynamic-dns
- Language: Svelte
- Homepage:
- Size: 1.35 MB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 11
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# google-domains-ddns-updater
Server to update [GoogleDomains Dynamic DNS](https://support.google.com/domains/answer/6147083?hl=en) entries for a list of domains.
Runs a cron job to make a request to google for each domain entered.
Exposes APIs to manage the domains entered, as well as manually trigger the job when needed.
Also exposes a WebUI (unprotected) that utilizes the APIs to provide easy management.
## hostnames.json file format
```
{
"hostnames": [
{
"domain": "google.com",
"username": "google",
"password": "elgoog"
}
]
}
```## WebUI
```
visit http://localhost:8000 in your browser
```## API Endpoints (unsecured, unvalidated)
```
[GET]
/api/hostnames[GET]
/api/hostnames/domain.com[POST]
/api/hostnames
{
"domain": "google.com",
"username": "google",
"password": "elgoog"
}[PUT]
/api/hostnames/domain.com
{
"username": "google",
"password": "elgoog"
}[DELETE]
/api/hostnames/domain.com[GET]
/api/triggerUpdate
```# Running in production
## Use latest docker image
```
docker pull stevenweathers/google-domains-ddns-updater
```## Use latest released binary
[![](https://img.shields.io/github/v/release/stevenweathers/google-domains-ddns-updater?include_prereleases)](https://github.com/StevenWeathers/google-domains-ddns-updater/releases/latest)
# Running locally
## Building and running with Docker (preferred solution)
### Using Docker Compose
```
docker-compose up --build
```### Using Docker without Compose
This solution will require you to pass environment variables or setup the config file, as well as setup and manage the DB yourself.
```
docker build ./ -f ./build/Dockerfile -t gddu:latest
docker run --publish 8080:8080 --name gddu gddu:latest
```## Building
### Install dependencies
```
go get
npm install
```## Build with Make
```
make build
```
### OR manual steps### Build static assets
```
npm run build
```### Build for current OS
```
go build
```# Adding new Locale's
Using svelte-i18n **Google Domains DDNS Updater** now supports Locale selection on the UI (Default en-US)Adding new locale's involves just a couple of steps.
1. First add the locale dictionary json files in ```web/public/lang/default/``` and ```web/public/lang/friendly/``` by copying the en.json and just changing the values of all keys
1. Second, the locale will need to be added to the locales list used by switcher component in ```web/config.js``` ```locales``` object# Configuration
Thunderdome may be configured through environment variables or via a yaml file `config.yaml`
located in one of:* `/etc/google-domains-ddns-updater/`
* `$HOME/.config/google-domains-ddns-updater/`
* Current working directoryThe following configuration options exists:
| Option | Environment Variable | Description | Default Value |
| -------------------------- | -------------------- | ------------------------------------------ | ------------------------|
| `http.port` | PORT | Which port to listen for HTTP connections. | 8000 |
| `http.path_prefix` | PATH_PREFIX | Prefix added to all application urls for shared domain use, in format of `/{prefix}` e.g. `/gddu` | |
| `config.toast_timeout` | CONFIG_TOAST_TIMEOUT | Number of milliseconds before notifications are hidden. | 1000 |
| `config.default_locale` | CONFIG_DEFAULT_LOCALE | The default locale (language) for the UI | en |
| `config.json_path` | JSONPATH | The path where the json file is stored | data/hostnames.json |
| `config.cadence` | CADENCE | The cadence at which the cron will run | @hourly |