add ingress node pool

This commit is contained in:
wizzdom 2024-01-23 04:38:58 +00:00
parent 6f6692d89a
commit 8d91938ee2
4 changed files with 16 additions and 15 deletions

5
cluster-config/README.md Normal file
View file

@ -0,0 +1,5 @@
# Nomad Cluster Configuration
This directory contains configuration relating to the configuration of the cluster including:
- node pools
- agent config

View file

@ -0,0 +1,3 @@
node_pool "ingress" {
description = "Nodes for ingress to aperture. e.g. bastion-vm"
}

View file

@ -1,14 +1,9 @@
job "mc-router" {
job "gate-proxy" {
datacenters = ["aperture"]
node_pool = "ingress"
type = "service"
constraint {
attribute = "${attr.unique.hostname}"
value = "bastion-vm"
}
group "mc-router" {
group "gate-proxy" {
count = 1
network {
@ -27,7 +22,7 @@ job "mc-router" {
}
}
task "webserver" {
task "gate-proxy" {
driver = "docker"
config {
@ -47,9 +42,11 @@ job "mc-router" {
config:
bind: 0.0.0.0:4501
forwarding:
mode: legacy
lite:
enabled: true
routes:
- host: fugitives.rb.dcu.ie
backend: fugitives-mc.service.consul:25566

View file

@ -1,12 +1,8 @@
job "traefik" {
datacenters = ["aperture"]
node_pool = "ingress"
type = "service"
constraint {
attribute = "${attr.unique.hostname}"
value = "bastion-vm"
}
group "traefik" {
network {
port "http"{