Hephaestus is a server-side daemon written in Go, designed for automated management of TLS certificates for domains.
The service runs as a long-living background process (typically via docker-compose) and:
- synchronizes domains from configuration with the database;
- tracks certificate expiration dates;
- automatically renews certificates before they expire;
- operates fully in the background without any HTTP or REST API.
IMPORTANT: Hephaestus is no longer an API service. All behavior is driven by configuration, database state, and an internal scheduler.
- Automatic creation and renewal of TLS certificates
- Support for multiple domains and alternative (SAN) domains
- Periodic scheduler for certificate renewal
- Persistent state stored in PostgreSQL
- Runs as a daemon / background service
- Configuration via YAML and environment variables
After startup, the service performs two core steps:
On startup, Hephaestus:
- reads the list of domains from the configuration file;
- compares them with the current state in the database;
- creates, updates, or deletes domain records in the database to match the configuration.
This allows domain management to be declarative — the configuration file is the single source of truth.
After domain synchronization, the internal scheduler is started:
- runs at a fixed interval defined by
certs.renewal_duration; - checks all active domains stored in the database;
- if a certificate expires in less than 30 days, a renewal process is triggered automatically.
The scheduler continues running as long as the service is alive.
Simplified project structure:
cmd/
hephaestus/ # application entry point (main)
internal/
app/ # application bootstrap and wiring
service/ # core business logic
scheduler/ # background scheduler
platform/
db/ # database access and transactions
logger/ # logging
migrations/ # SQL migrations
config/ # configuration examples
- Docker and Docker Compose
- PostgreSQL
- Access to DNS providers (for DNS-01 verification)
Hephaestus is intended to be run via docker-compose.
Example:
docker-compose up -dThe container starts the Hephaestus binary and passes the configuration file path via the CONFIG_PATH environment variable.
Configuration is defined in a YAML file and loaded on service startup.
app:
name: hephaestus
version: "2.0.0"
log_level: info
db:
postgres:
host: postgres
port: 5432
user: hephaestus
password: secret
database: hephaestus
sslmode: disable
time_zone: UTC
migration_path: ./migrations
certs:
storage_dir: /certs
email: admin@example.com
renewal_duration: 24h
domains:
- name: example.com
alternative_domains:
- name: www.example.com
created_by: config
verification_method: dns
auto_renew: true
dns_provider: cloudflare
created_by: configapp:
name: hephaestus
version: "1.0.0"Informational metadata.
log_level: infoAvailable values:
tracedebuginfowarnerrorfatal
PostgreSQL connection settings.
Required field:
password
certs:
storage_dir: /certs
email: admin@example.com
renewal_duration: 24hstorage_dir— directory for certificate storageemail— ACME account emailrenewal_duration— how often the renewal check runs
List of domains managed by the service.
domains:
- name: example.com
alternative_domains:
- name: www.example.com
created_by: config
verification_method: dns
auto_renew: true
dns_provider: cloudflare
created_by: configname— primary domainalternative_domains— SAN domainsverification_method— verification method (e.g.dns)auto_renew— enable automatic renewaldns_provider— DNS provider name
- Configuration is loaded (
CONFIG_PATH) - PostgreSQL connection is established
- Domains are synchronized with the database
- Certificate renewal scheduler is started
- Service runs in the background until stopped
- REST API removed
- No HTTP endpoints
- Runs as a background daemon
- Domain management via configuration file
- Fully automated lifecycle
All logs are written to container stdout/stderr.
To follow logs:
docker logs -f hephaestusMIT