ansible-community / ansible-nomad

:watch: Ansible role for Nomad
https://galaxy.ansible.com/brianshumate/nomad
BSD 2-Clause "Simplified" License
294 stars 163 forks source link

Add automatic encryption key setup #117

Closed ygalblum closed 3 years ago

ygalblum commented 3 years ago

Tasks

Add task file for reading or generating thye gossip encryption key Include the new task file for servers when nomad_encrypt_enable is true and nomad_encrypt is not defined

Parameters

Add a new parameter nomad_encrypt_enable to force the creating of the encryption key nomad_encrypt_enable may also be set with the environment variable NOMAD_ENCRYPT_ENABLE nomad_encrypt is no longer defined by default Maintain backward compatability (Playbooks that set nomad_encrypt do not need to change)

Templates

server.hcl.js - Since nomad_encrypt is no longer defined by default, use jinja2 default filter

Fixes #68

ygalblum commented 3 years ago

@lanefu FYI

lanefu commented 3 years ago

awesome thanks @ygalblum !