Skip to main content

A SDK/helper library to work with Glesys API.

Project description

glesys

A Python library to interact with the Glesys.com API endpoints.
It's also a CLI tool to access a subset of all those features as well as housing a LetsEncrypt certbot Authenticator plugin.

Small Disclaimer: I have no affiliation with Glesys, I just appreciate their API and services

Installation

$ pip install glesys

Usage

:information_source: This assumes a valid glesys.toml configuration.

List all domains

$ glesys dns --all-domains

List all records for hvornum.se

$ glesys dns --all-records hvornum.se

LetsEncrypt challenge

:warning: This assumes you have installed this library locally on the machine before running the certbot utility. This is because certbot will use plugin-discovery via Entry points for plugins. This also requires a valid glesys.toml.

Single certificate for all domains

$ sudo glesys lets-encrypt --all-domains

This will generate certificates for all domains hosted under the Glesys DNS server. This would be eqivilant of running certbot manually for hvornum.se and archlinux.life:

certbot -v certonly --non-interactive --authenticator dns-glesys --preferred-challenges dns --dry-run --server https://acme-staging-v02.api.letsencrypt.org/directory --work-dir /home/anton/github/python-glesys/certbot --logs-dir /home/anton/github/python-glesys/certbot --config-dir /home/anton/github/python-glesys/certbot --text --agree-tos --email anton@hvornum.se --expand --renew-by-default -d '*.hvornum.se,hvornum.se,*.archlinux.life,archlinux.life'

By default it will run against LetsEncrypt staging environment. Use --production to target glesys lets-encrypt against the production endpoint of LetsEncrypt and to remove the dryrun.

Separate certificate for all domains

TBD!

$ sudo glesys lets-encrypt --all-domains --individual

Separate certificate for selected domains

TBD!

$ sudo glesys lets-encrypt --individual --hostname '*.hvornum.se' --hostname 'hvornum.se'

Supported API Endpoints

As of 2023-05-03 API Doc Spec.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

glesys-0.2.tar.gz (32.1 kB view details)

Uploaded Source

Built Distribution

glesys-0.2-py3-none-any.whl (35.4 kB view details)

Uploaded Python 3

File details

Details for the file glesys-0.2.tar.gz.

File metadata

  • Download URL: glesys-0.2.tar.gz
  • Upload date:
  • Size: 32.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.10

File hashes

Hashes for glesys-0.2.tar.gz
Algorithm Hash digest
SHA256 6970135159279c8499cd109f094fc029b283c713569ab53645bae5a9a5a595d2
MD5 78a60f9b7276e90f677aa0a13cc9a1d2
BLAKE2b-256 9fbe65057a5294242bdb7b0fe6fae749dc01c4af58e46b6a117a5975673b0a80

See more details on using hashes here.

File details

Details for the file glesys-0.2-py3-none-any.whl.

File metadata

  • Download URL: glesys-0.2-py3-none-any.whl
  • Upload date:
  • Size: 35.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.10

File hashes

Hashes for glesys-0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 84d4cc6130d20c97602355afdff012d81177b015384133381964512419dda823
MD5 d33aa05934844be4c507d4c44154ebd8
BLAKE2b-256 fa8fa1439c351cbbf1d3c4f4aa65073ad2ee789b43b6c21a3987d7c260e72c94

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page