Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
vmware-vsphere-cli-centos7.sh
#!/bin/bash
# Install required packages
yum makecache all
yum -y install openssl-devel cpan perl-Devel-StackTrace perl-Class-Data-Inheritable perl-Convert-ASN1 perl-Crypt-OpenSSL-RSA perl-Crypt-OpenSSL-X509 perl-Exception-Class perl-Archive-Zip perl-Path-Class perl-Try-Tiny perl-Crypt-SSLeay perl-Class-MethodMaker perl-Data-UUID perl-Data-Dump perl-SOAP-Lite perl-XML-SAX perl-XML-NamespaceSupport perl-libxml-perl perl-XML-LibXML perl-Socket6 perl-IO-Socket-INET6 perl-Net-INET6Glue
# Install perl modules with specific version
PERL_MM_USE_DEFAULT=1 cpan install BINGOS/ExtUtils-MakeMaker-6.96.tar.gz LEONT/Module-Build-0.4205.tar.gz GBARR/libnet-1.22.tar.gz GAAS/libwww-perl-5.837.tar.gz PERLER/UUID-Random-0.04.tar.gz
# Unattended vspherecli install
yes | PAGER=cat ./vmware-install.pl --default
@Marakai

This comment has been minimized.

Copy link

Marakai commented Oct 3, 2017

You just save me hours of trouble-shooting! This works beautifully without any user intervention, which I need for automatic deployment.

PS: Looks like IO::Compress::Zlib::Extra is also out of date by default. Had to grab a newer one from CPAN.

@RobertPaasche

This comment has been minimized.

Copy link

RobertPaasche commented Jul 28, 2018

Development Tools are required too

yum groups install "Development Tools"

And YAML
cpan install YAML

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.