Initial IaC setup: Nomad, Consul, Terraform, Ansible
- Ansible roles for Nomad and Consul installation - Nomad job specs for Traefik and monitoring stack - Terraform configuration for Nomad job management - Enterprise naming convention inventory - HashiCorp stack deployment playbook
This commit is contained in:
@@ -0,0 +1,53 @@
|
||||
# Nomad Configuration
|
||||
# Managed by Ansible - Do not edit manually
|
||||
|
||||
datacenter = "{{ datacenter }}"
|
||||
data_dir = "{{ nomad_data_dir }}/data"
|
||||
bind_addr = "0.0.0.0"
|
||||
|
||||
advertise {
|
||||
http = "{{ ansible_host }}"
|
||||
rpc = "{{ ansible_host }}"
|
||||
serf = "{{ ansible_host }}"
|
||||
}
|
||||
|
||||
# Enable ACLs (after bootstrap)
|
||||
# acl {
|
||||
# enabled = true
|
||||
# }
|
||||
|
||||
# Consul integration
|
||||
consul {
|
||||
address = "127.0.0.1:8500"
|
||||
|
||||
server_service_name = "nomad"
|
||||
client_service_name = "nomad-client"
|
||||
|
||||
auto_advertise = true
|
||||
server_auto_join = true
|
||||
client_auto_join = true
|
||||
}
|
||||
|
||||
# Vault integration (after Vault setup)
|
||||
# vault {
|
||||
# enabled = true
|
||||
# address = "http://127.0.0.1:8200"
|
||||
# }
|
||||
|
||||
telemetry {
|
||||
collection_interval = "10s"
|
||||
disable_hostname = true
|
||||
prometheus_metrics = true
|
||||
publish_allocation_metrics = true
|
||||
publish_node_metrics = true
|
||||
}
|
||||
|
||||
plugin "docker" {
|
||||
config {
|
||||
allow_privileged = true
|
||||
volumes {
|
||||
enabled = true
|
||||
}
|
||||
extra_labels = ["job_name", "task_group_name", "task_name", "namespace", "node_name"]
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user