Skip to content
Snippets Groups Projects

Don't use `/etc/hosts` to configure service discovery.

Closed Tom Prince requested to merge dont-use-etc-hosts into develop
5 unresolved threads

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
19 19 '';
20 20 };
21 monitoringEndpoint = lib.mkOption {
22 type = lib.types.str;
23 description = ''
24 The IPv4 address of the monitoring node this node should conenct to.
25 '';
26 };
21 27 monitoringvpnIPv4 = lib.mkOption {
22 28 type = lib.types.str;
23 29 description = ''
24 30 The IPv4 address of this node on the monitoring VPN.
25 31 '';
26 32 };
27 monitoringvpnEndpoint = lib.mkOption {
33 monitoringvpnPublicEndpoint = lib.mkOption {
  • 57 63 # qualified domain name.
    58 64 deployment.targetHost = config.networking.fqdn;
    59 65
    60 networking.hosts = {
    61 # To stream logs to the monitoring host, all nodes need to know its address
    62 ${nodes.monitoring.config.services.private-storage.monitoring.vpn.server.ip} = [
    63 "monitoring" "monitoring.monitoringvpn"
    64 ];
    65 };
    66 # This is the host that nodes should connect to for push-based monitoring.
    67 # Note that this needs to be overridden on the monitoring host, otherwise
    68 # we'd end up with infinite recursion.
    69 grid.monitoringEndpoint = nodes.monitoring.config.grid.monitoringEndpoint;
  • 1 1 let
    2 pkgs = import <nixpkgs> { };
    3
    4 2 gridlib = import ../../lib;
    5 grid-config = pkgs.lib.trivial.importJSON ./config.json;
    3 grid-config = gridlib.pkgs.lib.trivial.importJSON ./config.json;
  • 18 18 corresponding private keys for the system.
    19 19 '';
    20 20 };
    21 monitoringEndpoint = lib.mkOption {
    22 type = lib.types.str;
    23 description = ''
    24 The IPv4 address of the monitoring node this node should conenct to.
  • Florian Sesser mentioned in commit e9b28a79

    mentioned in commit e9b28a79

  • Florian Sesser deleted the 207.payment-server-exception-reporting-update branch. This merge request now targets the develop branch

    deleted the 207.payment-server-exception-reporting-update branch. This merge request now targets the develop branch

    • I did move the promtail "clients" config into the promtail.nix file and did some advance service discovery for them computers, hr hr, in e9b28a79, and would not use this MR since the infinite loop bothers me.

      I like your using the gridlib nix pkgs, would you not advise that for all three grids?

    • Author Developer

      would not use this MR since the infinite loop bothers me.

      I posted a way to avoid the infinite loop here.

      I like your using the gridlib nix pkgs, would you not advise that for all three grids?

      Yeah, that would be reasonable, as would open coding importJSON <file> as fromJSON (readFile <file>)).

    • Please register or sign in to reply
  • Florian Sesser mentioned in merge request !269 (merged)

    mentioned in merge request !269 (merged)

  • I created a separate MR for Tom's proposed clean-ups: !269 (merged).

    The rest is more complexity than I want to have.

  • Please register or sign in to reply
    Loading