const hostYaml = (ipv4Ip: string, ipv6Ip: string) => {
  return `#generated by ui form view
#ipv4MachineNetwork 192.168.1.222/11
#ipv6MachineNetwork 2345::ff/21
interfaces:
  - name: eth0.22
    type: vlan
    state: up
    vlan:
      base-iface: eth0
      id: 22
    ipv4:
      address:
        - ip: ${ipv4Ip}
          prefix-length: 11
      enabled: true
      dhcp: false
    ipv6:
      address:
        - ip: ${ipv6Ip}
          prefix-length: 21
      enabled: true
      dhcp: false
dns-resolver:
  config:
    server:
      - 192.168.1.22
routes:
  config:
    - destination: 0.0.0.0/0
      next-hop-address: 192.168.1.224
      next-hop-interface: eth0.22
      table-id: 254
    - destination: '::/0'
      next-hop-address: 2345:0425:2CA1:0000:0000:0567:5673:23b5
      next-hop-interface: eth0.22
      table-id: 254
`;
};

const hostMap = (macAddress: string) => {
  return [
    {
      logical_nic_name: 'eth0',
      mac_address: macAddress,
    },
  ];
};

export const dualStackHostConfigs = [
  {
    mac_interface_map: hostMap('00:00:5e:00:53:a1'),
    network_yaml: hostYaml('192.168.3.28', '2345:0425:2CA1:0000:0000:0567:5673:23ba'),
  },
  {
    mac_interface_map: hostMap('00:00:5e:00:53:ae'),
    network_yaml: hostYaml('192.168.3.34', '2345:0425:2CA1:0000:0000:0567:5673:23b1'),
  },
  {
    mac_interface_map: hostMap('00:00:5e:00:53:af'),
    network_yaml: hostYaml('192.168.3.37', '2345:0425:2CA1:0000:0000:0567:5673:23b3'),
  },
];
