Project

General

Profile

Feature #18765

Use hostname instead IP address for finish script

Added by Lukas Zapletal over 1 year ago. Updated 4 months ago.

Status:
Closed
Priority:
Normal
Category:
Compute resources
Target version:
Difficulty:
easy
Triaged:
No
Bugzilla link:
Team Backlog:
Fixed in Releases:
Found in Releases:

Description

In DHCP-less or external-DHCP environments, image-based provisioning cannot be seeded for virtualized environments.

We need to have opt-in option to use DNS name instead IP address for SSH checks, that will solve the issue. This must be opt-in to prevent mis-provisioning. Also users need to be aware that password or ssh key must be correct in order to connect, it's recommended to change the default password on the image after system is provisioned to something different for production systems.


Related issues

Related to Foreman - Feature #18766: Acquire IP address from virtualization environments when possibleNew2017-03-02
Related to Foreman - Bug #9410: Finish script should try connect to hostname when IP address is emptyRejected2015-02-17
Related to Foreman - Feature #18769: add a DNS based IPAMNew2017-03-02

Associated revisions

Revision 8397b3c9 (diff)
Added by Lukas Zapletal 5 months ago

Fixes #18765 - finish script use FQDN when IP is missing

This is resurrect of

https://github.com/theforeman/foreman/pull/2171/files

The old patch did not pass review because I was unable to explain the
motivation. The reason for the fallback is that only cloud compute
resources usually provide IP addresses but virtualization do not. Our
users often associate finish templates with libvirt or VMWare but it
does not work at all. This only applies to externally managed networks
where we don't know the IP (no reservation made by Foreman).

Now there is a question of safety, with incorrect DNS setup, Foreman
could run finish script on incorrect server. Therefore I am sending this
patch for discussion - I think I could make this behavior an opt-it via
setting.

History

#1 Updated by Lukas Zapletal over 1 year ago

  • Related to Feature #18766: Acquire IP address from virtualization environments when possible added

#2 Updated by Dominic Cleal over 1 year ago

  • Related to Bug #9410: Finish script should try connect to hostname when IP address is empty added

#3 Updated by Timo Goebel over 1 year ago

#4 Updated by Lukas Zapletal over 1 year ago

Damn, I don't know what you do Dominic, but I never find what is in RedMine... I was checking that and failed. I assume you do Ctrl+F on lists, crazy.

#5 Updated by The Foreman Bot over 1 year ago

  • Status changed from New to Ready For Testing
  • Assignee set to Lukas Zapletal
  • Pull request https://github.com/theforeman/foreman/pull/4370 added

#6 Updated by Lukas Zapletal 5 months ago

  • % Done changed from 0 to 100
  • Status changed from Ready For Testing to Closed

#7 Updated by Marek Hulán 5 months ago

  • Triaged set to No
  • Legacy Backlogs Release (now unused) set to 353

Also available in: Atom PDF