Page MenuHomeSoftware Heritage

vagrant: Fix dns search domains per deployment
ClosedPublic

Authored by ardumont on Jan 27 2022, 4:01 PM.

Details

Summary

This fixes the wrong fqdn computations which leads to puppet development side-tracks.

Related to T3895

Test Plan

No issue on production/staging/admin nodes as they have the correct values already

$SWH_PUPPET_ENVIRONMENT_HOME/bin/octocatalog-diff --octocatalog-diff-args --no-truncate-details --to staging rp1.internal.admin.swh.network
Found host rp1.internal.admin.swh.network
WARN     -> Environment "staging-add-prometheus-metrics" contained non-word characters, correcting name to staging_add_prometheus_metrics
WARN     -> Environment "staging-bullseye-rabbitmq-plugin" contained non-word characters, correcting name to staging_bullseye_rabbitmq_plugin
WARN     -> Environment "staging-check-journal-client" contained non-word characters, correcting name to staging_check_journal_client
WARN     -> Environment "staging-check-journal-client-2nd-implementation" contained non-word characters, correcting name to staging_check_journal_client_2nd_implementation
WARN     -> Environment "staging-check-journal-client-first-implem" contained non-word characters, correcting name to staging_check_journal_client_first_implem
WARN     -> Environment "staging-pin" contained non-word characters, correcting name to staging_pin
WARN     -> Environment "staging-sentry" contained non-word characters, correcting name to staging_sentry
Cloning into '/tmp/swh-ocd.qTJzVEKM/environments/production/data/private'...
done.
Cloning into '/tmp/swh-ocd.qTJzVEKM/environments/staging/data/private'...
done.
*** Running octocatalog-diff on host rp1.internal.admin.swh.network
I, [2022-01-27T15:59:41.746293 #675533]  INFO -- : Catalogs compiled for rp1.internal.admin.swh.network
I, [2022-01-27T15:59:42.179252 #675533]  INFO -- : Diffs computed for rp1.internal.admin.swh.network
I, [2022-01-27T15:59:42.179293 #675533]  INFO -- : No differences
*** End octocatalog-diff on rp1.internal.admin.swh.network
 swh  tony  yavin4  ~  work  …  repo  swh  puppet-environment   master  1⬆  1✎  1+  5⚑  %  $SWH_PUPPET_ENVIRONMENT_HOME/bin/octocatalog-diff --octocatalog-diff-args --no-truncate-details --to staging rp0.internal.staging.swh.network
Found host rp0.internal.staging.swh.network
WARN     -> Environment "staging-add-prometheus-metrics" contained non-word characters, correcting name to staging_add_prometheus_metrics
WARN     -> Environment "staging-bullseye-rabbitmq-plugin" contained non-word characters, correcting name to staging_bullseye_rabbitmq_plugin
WARN     -> Environment "staging-check-journal-client" contained non-word characters, correcting name to staging_check_journal_client
WARN     -> Environment "staging-check-journal-client-2nd-implementation" contained non-word characters, correcting name to staging_check_journal_client_2nd_implementation
WARN     -> Environment "staging-check-journal-client-first-implem" contained non-word characters, correcting name to staging_check_journal_client_first_implem
WARN     -> Environment "staging-pin" contained non-word characters, correcting name to staging_pin
WARN     -> Environment "staging-sentry" contained non-word characters, correcting name to staging_sentry
Cloning into '/tmp/swh-ocd.9PVsdcpy/environments/production/data/private'...
done.
Cloning into '/tmp/swh-ocd.9PVsdcpy/environments/staging/data/private'...
done.
*** Running octocatalog-diff on host rp0.internal.staging.swh.network
I, [2022-01-27T16:00:00.824162 #677271]  INFO -- : Catalogs compiled for rp0.internal.staging.swh.network
I, [2022-01-27T16:00:01.307497 #677271]  INFO -- : Diffs computed for rp0.internal.staging.swh.network
I, [2022-01-27T16:00:01.307542 #677271]  INFO -- : No differences
*** End octocatalog-diff on rp0.internal.staging.swh.network
 swh  tony  yavin4  ~  work  …  repo  swh  puppet-environment   master  1⬆  1✎  1+  5⚑  %  $SWH_PUPPET_ENVIRONMENT_HOME/bin/octocatalog-diff --octocatalog-diff-args --no-truncate-details --to staging worker01
Found host worker01.softwareheritage.org
WARN     -> Environment "staging-add-prometheus-metrics" contained non-word characters, correcting name to staging_add_prometheus_metrics
WARN     -> Environment "staging-bullseye-rabbitmq-plugin" contained non-word characters, correcting name to staging_bullseye_rabbitmq_plugin
WARN     -> Environment "staging-check-journal-client" contained non-word characters, correcting name to staging_check_journal_client
WARN     -> Environment "staging-check-journal-client-2nd-implementation" contained non-word characters, correcting name to staging_check_journal_client_2nd_implementation
WARN     -> Environment "staging-check-journal-client-first-implem" contained non-word characters, correcting name to staging_check_journal_client_first_implem
WARN     -> Environment "staging-pin" contained non-word characters, correcting name to staging_pin
WARN     -> Environment "staging-sentry" contained non-word characters, correcting name to staging_sentry
Cloning into '/tmp/swh-ocd.bpH7ct0I/environments/production/data/private'...
done.
Cloning into '/tmp/swh-ocd.bpH7ct0I/environments/staging/data/private'...
done.
*** Running octocatalog-diff on host worker01.softwareheritage.org
I, [2022-01-27T16:00:24.932534 #679067]  INFO -- : Catalogs compiled for worker01.softwareheritage.org
I, [2022-01-27T16:00:25.509286 #679067]  INFO -- : Diffs computed for worker01.softwareheritage.org
I, [2022-01-27T16:00:25.509327 #679067]  INFO -- : No differences
*** End octocatalog-diff on worker01.softwareheritage.org

But that fixes vagrant node appliance:

Notice: /Stage[main]/Resolv_conf/File[/etc/resolv.conf]/content:
--- /etc/resolv.conf    2022-01-27 14:37:52.220000000 +0000
+++ /tmp/puppet-file20220127-6155-1phehyo       2022-01-27 14:56:01.016000000 +0000
@@ -1,5 +1,4 @@
 # File managed by puppet

-# search internal.softwareheritage.org softwareheritage.org
-search internal.admin.swh.network softwareheritage.org
+search internal.admin.swh.network

Diff Detail

Repository
rSPSITE puppet-swh-site
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.