Projet

Général

Profil

Actions

Anomalie #1264

fermé

DNS interne pour l'environnement de test

Ajouté par Quentin CHERGUI il y a environ 11 ans. Mis à jour il y a environ 5 ans.

Statut:
Fermé
Priorité:
Normale
Assigné à:
Catégorie:
Task
Version cible:
Début:
30/04/2013
Echéance:
% réalisé:

100%

Temps estimé:
Temps passé:
Difficulté:
3 Moyen

Description

Lors de l'écriture des tests dans April-Ci, le problème de la résolutions des noms externes (comme april.org) dans l'environnement de test est apparu (par exemple, les scénarios Cucumber ont besoin d'avoir un FQDN indiqué).

Pour que ces noms externent pointent vers l'environnement de test, il faut un résolveur DNS interne qui fasse correspondre chaque nom externe à son équivalent dans l'environnement de test (en .novalocal).

  • each instance runs a spoof_dns instance that overrides some DNS entries
    fqdn2fqdn = {
        'foo.com': 'foo.me',
        'bar.com': 'bar.me',
    }
    
  • the spoof_dns forwards the novalocal zone to the OpenStack provided resolver found in the resolv.conf of the instance at boot time
  • the dhclient is configured to prepend unbound to /etc/resolv.conf so that it is always used as a resolveer
    /etc/dhcp/dhclient.conf:prepend domain-name-servers 127.0.0.1;
    
  • a script parses the manifest files and creates fqdn2fqdn entries to *.novalocal for each node name, using the spoof_dns syntax
  • when in a test environment (determined by the is_april_ci varilable found in the params file used to store password ) the april_ci_dns class is activated to run spoof_dns on the instance
Actions

Formats disponibles : Atom PDF