diff --git a/ansible/era.yml b/ansible/era.yml index e16e15c..2ffe120 100644 --- a/ansible/era.yml +++ b/ansible/era.yml @@ -13,6 +13,7 @@ become: true hosts: - metal-03.he-eu-hel1.nimbus.mainnet + - linux-01.he-eu-hel1.nimbus.prater roles: - role: origin-certs tags: origin-certs diff --git a/ansible/host_vars/linux-01.he-eu-hel1.nimbus.prater.yml b/ansible/host_vars/linux-01.he-eu-hel1.nimbus.prater.yml index 37e1599..8c3a254 100644 --- a/ansible/host_vars/linux-01.he-eu-hel1.nimbus.prater.yml +++ b/ansible/host_vars/linux-01.he-eu-hel1.nimbus.prater.yml @@ -6,3 +6,29 @@ beacon_node_rest_address: '0.0.0.0' redirect_ports: # beacon-node-prater-unstable - { src: 80, dst: 9302, comment: 'Test Beacon API (80->9302/tcp)' } + +# Era files hosting +era_files_domain: 'prater.era.nimbus.team' +era_files_path: '/data/era' + +# CloudFlare Origin certificates +origin_certs: + - domain: 'nimbus.team' + crt: '{{lookup("bitwarden", "CloudFlare/nimbus.team", file="origin.crt")}}' + key: '{{lookup("bitwarden", "CloudFlare/nimbus.team", file="origin.key")}}' + +nginx_sites: + era_files: + - listen 80 default_server + - listen 443 ssl + + - server_name {{ era_files_domain }} + + - ssl_certificate /certs/nimbus.team/origin.crt + - ssl_certificate_key /certs/nimbus.team/origin.key + + - location / { + root {{ era_files_path }}; + autoindex on; + autoindex_format html; + } diff --git a/mainnet.tf b/mainnet.tf index 012ef7b..cdfbefb 100644 --- a/mainnet.tf +++ b/mainnet.tf @@ -40,7 +40,7 @@ resource "cloudflare_record" "testing_mainnet_beacon_api" { type = "A" proxied = false } - + /* ERA Files hosting */ resource "cloudflare_record" "era_mainnet" { zone_id = local.zones["nimbus.team"] diff --git a/prater.tf b/prater.tf index 6e1ef9b..2bb50bd 100644 --- a/prater.tf +++ b/prater.tf @@ -147,6 +147,15 @@ resource "cloudflare_record" "testing_prater_beacon_api" { proxied = false } +/* ERA Files hosting */ +resource "cloudflare_record" "era_prater" { + zone_id = local.zones["nimbus.team"] + name = "prater.era" + value = module.nimbus_nodes_prater_hetzner.public_ips[0] + type = "A" + proxied = true +} + module "nimbus_nodes_prater_macos" { source = "github.com/status-im/infra-tf-dummy-module"