Skip to content

Instantly share code, notes, and snippets.

<link rel="import" href="../core-scaffold/core-scaffold.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<link rel="import" href="../core-menu/core-menu.html">
<link rel="import" href="../core-item/core-item.html">
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-menu/core-submenu.html">
<polymer-element name="my-element">
@kanedafromparis
kanedafromparis / keybase.md
Created March 22, 2017 11:22
Keybase proof

Keybase proof

I hereby claim:

  • I am kanedafromparis on github.
  • I am csabourdin (https://keybase.io/csabourdin) on keybase.
  • I have a public key ASAEdjtWvyCxAV51vzy_xRojYDbC3Kz0BP3hXKAGVlFeqQo

To claim this, I am signing this object:

TIMESLOT=`date +%y%m%d%H%M%S`;
for proj in $(oc get project --show-labels -l zone!=production,role!=webhop --no-headers | cut -d " " -f 1); do
for dc in $(oc get dc -n $proj --show-labels -l zone!=production,role!=webhop --no-headers | cut -d " " -f 1); do
#echo " dc $dc --replicas=0 -n $proj " | tee -a $TIMESLOT-scaledown.log;
oc scale dc $dc --replicas=0 -n $proj | tee -a $TIMESLOT-scaledown.log;
done
done
apiVersion: v1
kind: Pod
metadata:
name: nginx-master
spec:
containers:
- name: nginx-m
image: nginx
ports:
- containerPort: 80
git fetch upstream &&
git merge remotes/upstream/master
git checkout -b "new-branch"
ENDPOINT=smtp
SERVICEPORT=25
timeout 1 bash -c 'cat < /dev/null > /dev/tcp/$ENDPOINT/$SERVICEPORT' ; echo $?
/tmp/test.sh > /dev/tcp/$ENDPOINT/$SERVICEPORT
$ cat /tmp/test.sh
#!/bin/bash
oc get packagemanifests -n openshift-marketplace
oc get Subscription,OperatorGroup,CatalogSourceConfig,CatalogSource,InstallPlan
oc get catalogsource -n openshift-marketplace
oc get CatalogSourceConfig -n openshift-marketplace
oc get packagemanifests -n openshift-marketplace | grep grafana
@kanedafromparis
kanedafromparis / gist:5b5b22889ca4673a06e70295108be4fd
Created October 10, 2019 07:58
Create operator grafana (exemple)
oc get packagemanifests -n openshift-marketplace | grep grafana
oc create -f CatalogSourceConfig.yaml
--
apiVersion: operators.coreos.com/v1
kind: CatalogSourceConfig
metadata:
name: test-cas-grafana-operator-csc
namespace: openshift-marketplace
spec:
csDisplayName: Community Operators
oc get --ignore-not-found $( oc api-resources --verbs=list --namespaced -o name | xargs | sed 's/\ /,/g')
oc get --ignore-not-found $( oc api-resources --verbs=list --namespaced -o name | xargs | sed 's/\ /,/g')