• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

virtuallyGhetto

  • About
  • Privacy
  • VMware Cloud
  • Home Lab
  • Nested Virtualization
  • Automation
    • VMware Kickstart
    • VMware API/SDK/CLI
    • VMware vMA/VIMA
    • VMware OVF / OVFTOOL
  • Apple Mac
  • VCSA
  • VSAN
You are here: Home / VAMI / Quick Tip – Configuring HTTP proxy for VAMI via CLI

Quick Tip – Configuring HTTP proxy for VAMI via CLI

04/20/2014 by William Lam 4 Comments

An HTTP Proxy is commonly used by customers who do not have direct internet access from within their datacenter to either upload logs or download patches from a particular website. I recently had to configure this within our environment to ensure we could patch against the external repository as we also have the same restriction as majority of our customers. To configure a proxy server for a VMware Virtual Appliance, you can do so using the VAMI interface under the Network section as seen in the screenshot below.

vami-proxy-configuration

I was looking to configure this from the command-line and through some quick test, here is how you do it. There is a command called /opt/vmware/share/vami/vami_set_proxy which accepts two parameters: proxy server and the proxy port.

Here is an example of how the command works:

/opt/vmware/share/vami/vami_set_proxy proxy.vghetto.com 3128

You can view the current proxy settings by running the following command:

/opt/vmware/share/vami/vami_proxy

There are two additional commands that show only the proxy server and proxy port respectively:

/opt/vmware/share/vami/vami_proxy_port
/opt/vmware/share/vami/vami_proxy_server

One thing you may have noticed is that these commands do not support configuring a proxy username or password as the VAMI UI does. After looking at the script does, I found that it is just writing it out into /etc/environment configuration file. If you require a proxy username and password, you could just directly edit the file and append the following as an example:

http_proxy=http://username:*protected email*:3128

More from my site

  • Patching VMware Virtual Appliances Using vamicli
  • How To Create Offline Update Repository For VMware Virtual Appliances
  • Configure network proxy using YTT with Tanzu Kubernetes Grid (TKG)
  • How to configure network proxy with Tanzu Kubernetes Grid (TKG)?
  • Packer reference for building PhotonOS Virtual Appliance using OVF properties 
Share this...
  • Twitter
  • Facebook
  • Linkedin
  • Reddit
  • Pinterest

Filed Under: VAMI Tagged With: http proxy, vami, virtual appliance

Reader Interactions

Comments

  1. Timo Sugliani says

    04/22/2014 at 6:27 am

    I think we should probably read “proxy.vghetto.com” instead of “proxy.vhgetto.com” in this post (I can feel the copy/paste) 😉

    Reply
    • William Lam says

      04/22/2014 at 2:26 pm

      haha thanks for the catch. I’ve fixed the typo, no wonder the proxy wasn’t working 😉

      Reply
  2. Gianluigi says

    05/06/2016 at 10:35 am

    Thanks William this old post pointed me in the right direction!
    VAMI running on VCSA 6u1 is not able to download the updates even with the proxy settings configured.
    I noted that the updates comes from an HTTPS site not a simple HTTP, so to enable the download via HTTPS I edited the proxy settings in the following file /etc/sysconfig/proxy
    I’m wondering why VMware doesn’t allow to use the same proxy settings not only for HTTP, but also HTTPS and http://FTP... Maybe they simply forgot to setup that option in VAMI interface… :-))

    Reply
  3. Simon Sparks says

    03/08/2017 at 1:00 am

    I have a vRealize Log Insight instance in a secure environment in which the only internet access is via a HTTP proxy but there is no VAMI 5480 available on the appliance.

    How do I configure the proxy settings ?

    Reply

Thanks for the comment! Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Primary Sidebar

Author

William Lam is a Senior Staff Solution Architect working in the VMware Cloud team within the Cloud Services Business Unit (CSBU) at VMware. He focuses on Automation, Integration and Operation for the VMware Cloud Software Defined Datacenters (SDDC)

  • Email
  • GitHub
  • LinkedIn
  • RSS
  • Twitter
  • Vimeo

Sponsors

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy