Unexpected behaviour in using Cloud and VLAN proxy

I’m currently using Community Edition v7.0.6 and have encountered unexpected behaviour when trying to deploy a Linux VM and have proxy settings applied to it.

Its a custom-created image of Ubuntu 22.04 LTS, from the live installation ISO provided by Canonical, and the Ubuntu-specific settings documented in Getting started with Morpheus and VMware — Morpheus Docs documentation have been applied to allow cloud-init to configure networking, etc.

Technology is VMWare, and the VM is deployed behind a forwarding proxy. Any outbound comms will go via this proxy, including comms back to the Morpheus appliance.

Using the instructions at Proxies — Morpheus Docs documentation I defined a proxy (Infrastructure > Networks > Proxies), and applied it to the VMWare Cloud (under the Provisioning Command option). I also disabled the option “Bypass Proxy for Appliance URL” with the understanding that with this turned off, the VM would try to connect to the Appliance URL through the proxy.

Looking at what happens on the server during the deployment, I can see that it will curl back to the Morpheus appliance to download the installation script, and then pipe it through bash, which then installs the morpheus-node package and configures /etc/morpheus/morpheus.rb and populates the config.yml file that the Morpheus node agent then uses upon startup.

From what I can tell, the proxy settings cause proxy-related environment variables to be populated into /etc/environment, and it exports those same variables during the cloud-init run. With the “Bypass Proxy for Appliance URL” option turned off, what I was expecting is for the no_proxy and https_no_proxy variables to not include the appliance URL as a value, but it does. And what then happens is the curl (to download the installation script) doesn’t go through the proxy, and the connection fails.

I found that instead of setting a proxy at the Cloud level, I could also set it at the Network/VLAN level, which I also tried (having removed the proxy setting at the Cloud level), and also unsetting the “Bypass Proxy for Appliance URL” option, but the behaviour remained the same. The no_proxy and https_no_proxy variables would include the appliance URL value, and the curl connection would fail.

Also, I did explicitly set values in the “No Proxy” setting but they didn’t seem to have any effect. Morpheus still included the exact same values (including the appliance URL) in environment variables with no reference to my values.

Is this the expected behaviour, as it seems to directly contradict what its telling me it will do? Or am I missing some additional configuration to ensure all outbound connections from the VM will use the proxy?

I can work around this, through my own cloud-init settings, but would prefer not to.

On a related note; setting a proxy at the Cloud level causes a proxy to be set in /etc/morpheus/morpheus.rb on the new VM (once you’ve sorted out the initial curl back to the appliance, and it has downloaded and installed the agent). However, setting the proxy at the Network/VLAN does not cause Morpheus to set the proxy in /etc/morpheus/morpheus.rb. I’m also not sure whether or not that’s the expected/intended behaviour - I was expecting the behaviour to be the same regardless of whether this was set at the Cloud or Network/VLAN level.

Hopefully I’ve clarified what I’m trying to achieve and how I’m going about it, but I’m happy to clarify further.

I’ve gone through documentation, discussion articles and forums but didn’t find anyone experiencing the same issue.

Hi @pieters. Welcome.

There’s a lot to unpack in your post.

Please open a Technical Request using tokens if forum cannot assist.