Page MenuHomePhabricator

Support instance creation/deletion via nova commandline
Closed, ResolvedPublic

Description

Everything that OpenStackManager does during creation and deletion should instead be done via Nova hooks. python-nova-ldap (T91987) does most of the work here, but there are a lot of related tasks.

Related Objects

Event Timeline

Andrew claimed this task.
Andrew raised the priority of this task from to Needs Triage.
Andrew updated the task description. (Show Details)
Andrew added a project: Cloud-Services.
Andrew subscribed.

Right now, new instances get two ldap records. The first is from OSM:

i-00000b91.eqiad.wmflabs, hosts, wikimedia.org

dn: dc=i-00000b91.eqiad.wmflabs,ou=hosts,dc=wikimedia,dc=org
objectClass: domainrelatedobject
objectClass: dnsdomain
objectClass: puppetclient
objectClass: domain
objectClass: dcobject
objectClass: top
puppetVar: use_dnsmasq=true
puppetVar: realm=labs
puppetVar: instanceproject=integration
puppetVar: instancename=integration-saltmaster
puppetClass: base
puppetClass: role::labs::instance
puppetClass: puppetmaster::autosigner
puppetClass: role::salt::masters::labs::project_master
l: eqiad
associatedDomain: i-00000b91.eqiad.wmflabs
associatedDomain: integration-saltmaster.eqiad.wmflabs
associatedDomain: i-00000b91.integration.eqiad.wmflabs
associatedDomain: integration-saltmaster.integration.eqiad.wmflabs
dc: i-00000b91.eqiad.wmflabs
aRecord: 10.68.18.24

The second is from a sink callback:

integration-saltmaster.integration.eqiad.wmflabs, hosts, wikimedia.org

dn: dc=integration-saltmaster.integration.eqiad.wmflabs,ou=hosts,dc=wikimedia,
dc=org
objectClass: domainrelatedobject
objectClass: dnsdomain
objectClass: puppetclient
objectClass: domain
objectClass: dcobject
objectClass: top
puppetVar: realm=labs
puppetVar: use_dnsmasq=true
puppetVar: instanceproject=integration
puppetVar: instancename=integration-saltmaster
puppetClass: base
puppetClass: role::labs::instance
l: eqiad
associatedDomain: TESTING-integration-saltmaster.integration.eqiad.wmflabs
associatedDomain: TESTING-integration-saltmaster.eqiad.wmflabs
dc: integration-saltmaster.integration.eqiad.wmflabs
aRecord: 10.68.18.24

What will it take for us to only use the latter?

In no particular order:

  • Change OSM editing feature so that it edits fqdn-style records rather than ec2id-style records
  • Rename all ec2-style records to fqdn-style records
  • Change sink callback to create live fqdn records rather than dummy records
  • Purge existing dummy records
  • Change puppet cert so it matches the new records: https://gerrit.wikimedia.org/r/#/c/202924/
  • Make sure puppet certs for deleted instances are deleted: https://gerrit.wikimedia.org/r/#/c/205897/

In order to switch to the new cert names, it's nice to have a consistent fqdn. So... can we make that depend on 'move all instances to new dns server'?

Change 217039 had a related patch set uploaded (by Andrew Bogott):
Use fqdn instead of ecid for ldap host dn

https://gerrit.wikimedia.org/r/217039

Change 217345 had a related patch set uploaded (by Andrew Bogott):
Remove two maintenance scripts.

https://gerrit.wikimedia.org/r/217345

Change 217416 had a related patch set uploaded (by Andrew Bogott):
Remove ldap host-entry creation and deletion from OSM.

https://gerrit.wikimedia.org/r/217416

Change 217345 merged by jenkins-bot:
Remove two maintenance scripts.

https://gerrit.wikimedia.org/r/217345

Change 217039 merged by jenkins-bot:
Use fqdn instead of ecid for ldap host dn

https://gerrit.wikimedia.org/r/217039

Change 217416 merged by jenkins-bot:
Remove ldap host-entry creation and deletion from OSM.

https://gerrit.wikimedia.org/r/217416

Change 218678 had a related patch set uploaded (by Andrew Bogott):
Use fqdn instead of ecid for ldap host dn

https://gerrit.wikimedia.org/r/218678

Change 218679 had a related patch set uploaded (by Andrew Bogott):
Remove ldap host-entry creation and deletion from OSM.

https://gerrit.wikimedia.org/r/218679

Change 218678 merged by jenkins-bot:
Use fqdn instead of ecid for ldap host dn

https://gerrit.wikimedia.org/r/218678

Change 218679 merged by jenkins-bot:
Remove ldap host-entry creation and deletion from OSM.

https://gerrit.wikimedia.org/r/218679

Andrew moved this task from To Do to Done on the Labs-Sprint-102 board.