Skip to content

Instantly share code, notes, and snippets.

View matthewcosgrove's full-sized avatar

Matthew Cosgrove matthewcosgrove

View GitHub Profile
# Some useful commands for reference
# https://docs.vmware.com/en/VMware-Horizon-Client-for-Windows/4.6/com.vmware.horizon.windows-client-46-install/GUID-AFB637E0-9395-4A71-8103-7D6DF0103295.html
# INSTALLDIR
# The path and folder in which Horizon Client is installed. For example:
# INSTALLDIR=""D:\abc\my folder""
# default is %ProgramFiles%VMware\VMware Horizon View Client
# The sets of double quotes that enclose the path enable the installer to interpret the space as a valid part of the path.
# RUN ON CMD.exe with Admin
choco install vmware-horizon-client -ia "INSTALLDIR=""D:\installs\VMWare"""
choco install git.install -ia "/DIR="D:\installs\Git""
choco install virtualbox -ia "INSTALLDIR=""D:\installs\VirtualBox"""
# from: https://github.com/stedolan/jq/issues/2154#issuecomment-653981166
# alternative to Gron
jq -r 'paths as $p | "\($p) = \(getpath($p))"'
jobs:
- name: upload-product
plan:
- aggregate:
- do:
- get: pcf-pipelines-tarball
- task: unpack-tarball
config:
platform: linux
image_resource:
govc pool.info -json /drinks-dc/host/drinks-cl/Resources/chardonnay | jq -r '.ResourcePools[].Vm[] | join(":")' | xargs govc ls -L
# relative path - not guaranteed to be unique
govc pool.info ${GOVC_RESOURCE_POOL}
# absolute path
govc pool.info /${GOVC_DATACENTER}/host/${GOVC_CLUSTER}/Resources/${GOVC_RESOURCE_POOL}
# relative path
govc datastore.info "${GOVC_DATASTORE}"
# Custom certs (taht were installed on Ubuntu) being recognised by python. For example ansible-galaxy
export REQUESTS_CA_BUNDLE=/etc/ssl/certs/ca-certificates.crt
# Or also could do
# $ sudo update-ca-certificates --fresh
# $ export SSL_CERT_DIR=/etc/ssl/certs
TMPDIR=""¬
TMPDIR=$(mktemp -d -t dynamic_inventory.XXXXXX)
trap 'rm -rf ${TMPDIR}' INT TERM QUIT EXIT
INVENTORY_FILE="${TMPDIR}"/inventory.yml
cat <<EOF > "${INVENTORY_FILE}"
all:
hosts:
${IP_ADDRESS}:
ansible_python_interpreter: /usr/bin/python3
#!/usr/bin/env bash
set -ue
export urls=( \
# BOSH release download
https://bosh.io \
# PCF API with metadata for upgrades
https://network.pivotal.io \
# PCF-Pipelines open-source updates
@matthewcosgrove
matthewcosgrove / 00FirewallRuleChecks.MD
Last active November 28, 2020 17:07
Network Dependency Checks

Prequisites to run scripts

requires bash v4+, netcat (nc), jq, spruce

@matthewcosgrove
matthewcosgrove / 01_install_steps.sh
Last active February 7, 2021 14:24
Updated for Catalina and mainly for Music Sequencing https://github.com/matthewcosgrove/macos-bootstrap
#!/bin/bash
# STEP 1: Mount bootable USB and clean up disks
# IMPORTANT: Catalina now introduces a different approach to Disks/Volumes: https://eclecticlight.co/2019/12/17/how-clean-re-installs-change-in-catalina/
# Erase everything for a proper clean install and then create a new GUID Partition Apple_APFS volume (equivalent to https://www.youtube.com/watch?v=PqfqcwmHowc&ab_channel=AjudaAqui)
# Can all be done through Disk Utility rather than terminal diskutil. You just need to create at least one volume otherwise the installer will not see the disk
# STEP 2: Install Catalina from bootable USB
# STEP 3: Download this gist from UI of GitHub "Download Zip