Never expose an unencrypted Consul gossip layer to public or untrusted networks. Always enable encryption in production.
Initial Configuration
To activate gossip encryption on a new Consul agent, add theencrypt key to your agent’s JSON configuration (e.g., /etc/consul.d/agent-config.json):
- Generate a new gossip key:
- Copy the output and paste it into the
"encrypt"field above. - Restart or start the Consul agent:
Key Parameters Overview
Modifying an Existing Cluster

consul reload does not apply encryption changes—you must restart each agent (systemctl restart consul).
Two flags manage the transition phase:
Follow these steps:
-
Generate a new encryption key
-
Distribute the key and disable enforcement
Update each agent’s config: -
Rolling restart #1
-
Enable outgoing encryption
-
Rolling restart #2
-
Enable incoming encryption
-
Rolling restart #3