Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(POOLER-167) Allow for network configuration at vm clone time #382

Merged
merged 1 commit into from
Jun 23, 2020

Conversation

rooneyshuman
Copy link
Contributor

@rooneyshuman rooneyshuman commented Jun 10, 2020

These changes check if a pool's configuration contains a network property. If so, at clone time, a vm's network device is reconfigured to the denoted network.

It is necessary to reconfigure the network device since all vm templates are set up to connect to network vmpooler.

The create_relocate_spec and create_clone_spec methods were also created to break up the work performed in the create_vm method.

@rooneyshuman
Copy link
Contributor Author

rooneyshuman commented Jun 12, 2020

This feature has been tested by:

  1. Temporarily updating the configuration of one of the vmpooler-dev pools to the following:
  - name: "dev-pool-C-3"
    template: "templates/redhat-7.2-x86_64-0.0.3"
    folder: "vmpooler-dev/dev-pool-C-3"
    datastore: "tintri-pix-2-vmpooler"
    clone_target: "acceptance2"
    size: 3
    datacenter: "pix"
    provider: "vsphere-ci65"
    network: "ops

* Note the addition of the network property at the bottom. All vm templates are currently configured to be connected to the network named vmpooler.

  1. Next, a request to vmpooler's /vm endpoint was sent in order to trigger the create_vm method.

  2. The new vm's IP address and configured network were then checked through vCenter:
    Screen Shot 2020-06-11 at 11 48 14 AM

  3. Finally, the vm was verified to be accessible via SSH:
    Screen Shot 2020-06-11 at 11 47 48 AM

@rooneyshuman rooneyshuman marked this pull request as ready for review June 12, 2020 15:10
@rooneyshuman rooneyshuman requested a review from a team as a code owner June 12, 2020 15:10
@rooneyshuman rooneyshuman force-pushed the pooler-167 branch 2 times, most recently from 3089248 to 196a439 Compare June 12, 2020 15:50
spec/rbvmomi_helper.rb Outdated Show resolved Hide resolved
@mattkirby mattkirby merged commit a2a3bb7 into master Jun 23, 2020
@mattkirby mattkirby deleted the pooler-167 branch June 23, 2020 21:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants