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

Fix onevnet provider for dns and network_mask #172

Merged

Conversation

jnoss
Copy link
Contributor

@jnoss jnoss commented Jul 20, 2015

This fixes the onevnet provider for setting dns and network_mask (parameter names didn't match; also needs to create a space separated array of dns servers). Also fixes an issue with string.to_a for ruby > 1.9.

The parameter names opennebula expects are DNS and NETWORK_MASK not
dnsservers and netmask, so switch them when writing out the template
to be used when creating the onevnet. (Similar to vlanid to VLAN_ID
already in place.)

Also, the DNS value needs to output a space-separated string.

Also, fix string to array for ruby > 1.9 - when reading in dns from
onevnet list -x need to parse a space separated string. Ruby 1.8 had
a string.to_a but ruby >1.9 doesn't, so use .split(" ") instead (works
on both ruby versions).
@jnoss jnoss force-pushed the fix_onevnet_provider_for_dns_and_network_mask branch from 1f26a94 to 3cd07cf Compare July 21, 2015 15:37
@jnoss
Copy link
Contributor Author

jnoss commented Jul 21, 2015

This is all set and ready for merge.

@rwaffen
Copy link
Contributor

rwaffen commented Jul 21, 2015

@tuxmea : please have a look at this, you are the one who wrote the types/providers initially 😄

@tuxmea
Copy link
Contributor

tuxmea commented Jul 21, 2015

looks good to me

rwaffen added a commit that referenced this pull request Jul 21, 2015
…etwork_mask

Fix onevnet provider for dns and network_mask
@rwaffen rwaffen merged commit d72a1b2 into epost-dev:master Jul 21, 2015
@jtriley jtriley deleted the fix_onevnet_provider_for_dns_and_network_mask branch July 22, 2015 00:48
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