Skip to content

Instantly share code, notes, and snippets.

View Boomatang's full-sized avatar

Jim Fitzpatrick Boomatang

View GitHub Profile
@Boomatang
Boomatang / ocmclusterstate.sh
Created June 26, 2020 08:15 — forked from dofinn/ocmclusterstate.sh
Get state of target cluster to trigger reminders of action.
#!/bin/bash
clusterIdentifier=$1
OCM=~/go/bin/ocm
/usr/local/bin/ocm-stg-login
clusterInfo=$(${OCM} cluster list --managed | grep ${clusterIdentifier})
clusterId=$(echo ${clusterInfo} | awk '{print $1}')
clusterName=$(echo ${clusterInfo} | awk '{print $2}')