https://github.com/mickaelbergem/gandi-livedns-zone-manager
Versioned DNS records manager, using Gandi's LiveDNS API
https://github.com/mickaelbergem/gandi-livedns-zone-manager
devops dns infrastructure-as-code python python3 script
Last synced: 12 days ago
JSON representation
Versioned DNS records manager, using Gandi's LiveDNS API
- Host: GitHub
- URL: https://github.com/mickaelbergem/gandi-livedns-zone-manager
- Owner: MickaelBergem
- Created: 2017-11-05T18:36:14.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2022-05-21T11:08:59.000Z (about 3 years ago)
- Last Synced: 2025-04-01T14:38:18.609Z (about 2 months ago)
- Topics: devops, dns, infrastructure-as-code, python, python3, script
- Language: Python
- Size: 6.84 KB
- Stars: 7
- Watchers: 0
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Gandi LiveDNS zone manager
The goal of this tool is to display and version the Gandi DNS records of a zone, through the LiveDNS API.
You will need your API key from the Security page in
[your Gandi account](https://account.gandi.net/).
Store it in a `api_key.txt` file, or in an environment variable, like in the following example:```bash
$ export GANDI_API_KEY=your_api_key
$ python3 livedns.py view
== Zone test-zone [587549ec-c25f-11e7-9d8f-00163e6dc886] ==
No domain associated with this zone.
1 records in this zone:CNAME 10800 example example.org.
```## Usage
```bash
# View all records for all zones
python3 livedns.py view
# Pull the records and store them in the /zones folder
python3 livedns.py pull
ls -l zones
# Create a new zone
python3 livedns.py new test-zone
# Push (upload) the local records stored in /zones to the API
python3 livedns.py push
```## Requirements
Python 3 with the `requests` module installed.