Skip to content

F #7675: option to configure FQDN for remote_addr#7677

Open
atodorov-storpool wants to merge 1 commit into
OpenNebula:masterfrom
atodorov-storpool:patch-44
Open

F #7675: option to configure FQDN for remote_addr#7677
atodorov-storpool wants to merge 1 commit into
OpenNebula:masterfrom
atodorov-storpool:patch-44

Conversation

@atodorov-storpool
Copy link
Copy Markdown
Contributor

Description

This way the resolver on the host will provide the IP address for tproxy to communicate with the opennebula-gate service. So, with a DNS view or a line in /etc/hosts file on the host(s) the tproxy service will pick the desired IP to connect to the opennebula-gate endpoint.

Branches to which this PR applies

  • master
  • one-7.2

  • Check this if this PR should not be squashed

@atodorov-storpool atodorov-storpool force-pushed the patch-44 branch 2 times, most recently from e33e9b2 to 394a327 Compare May 14, 2026 10:33
Comment thread src/vnm_mad/remotes/lib/tproxy.rb Outdated
remote_ip = Resolv.getaddress(conf[:remote_addr])
next unless remote_ip =~ Resolv::IPv4::Regex

OpenNebula.log_info "Resolved remote_addr #{conf[:remote_addr]} to #{remote_ip}"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't OpenNebula::DriverLogger.log_info be used here? 🤔

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep, forgot that the logging was refactored somewhere between 6.x and 7.x
will force-push updated patch

Comment thread src/vnm_mad/remotes/lib/tproxy.rb Outdated
OpenNebula.log_info "Resolved remote_addr #{conf[:remote_addr]} to #{remote_ip}"
conf[:remote_addr] = remote_ip
rescue Resolv::ResolvError
OpenNebula.log_warning "Can't resolve remote_addr #{conf[:remote_addr]}. Skipping."
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't OpenNebula::DriverLogger.log_warning be used here? 🤔

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep, forgot that the logging was refactored somewhere between 6.x and 7.x
will force-push updated patch

@sk4zuzu
Copy link
Copy Markdown
Contributor

sk4zuzu commented May 20, 2026

Maybe indicating inside OpenNebulaNetwork.conf (in comments) that using FQDN is now a possibility would help some users. 🤔

So the resolver on the host will provide the IP address for the opennebula-gate service. This way, with DNS view or a line in /etc/hosts the tproxy service will pick the desired IP to connect to the opennebula-gate
Copy link
Copy Markdown
Contributor

@sk4zuzu sk4zuzu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@rsmontero rsmontero added this to the Release 7.4 milestone May 20, 2026
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