Skip to content

Instantly share code, notes, and snippets.

$ oc -n openshift-marketplace get pods cluster-logging-66846d4f96-qhpqz -o yaml
apiVersion: v1
kind: Pod
metadata:
annotations:
k8s.v1.cni.cncf.io/networks-status: |-
[{
"name": "openshift-sdn",
"interface": "eth0",
"ips": [
$ oc get catalogsource cluster-logging -o yaml
apiVersion: operators.coreos.com/v1alpha1
kind: CatalogSource
metadata:
creationTimestamp: 2019-03-28T23:50:44Z
generation: 1
labels:
csc-owner-name: cluster-logging
csc-owner-namespace: openshift-marketplace
name: cluster-logging
$ oc get deploy
NAME READY UP-TO-DATE AVAILABLE AGE
cluster-logging-operator 1/1 1 1 41m
elasticsearch-clientdatamaster-0-1 1/1 0 1 40m
kibana
$ oc get deploy/elasticsearch-clientdatamaster-0-1 -o yaml
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
>oc -n openshift-operators get subscription elasticsearch-9bgsr -o yaml
apiVersion: operators.coreos.com/v1alpha1
kind: Subscription
metadata:
creationTimestamp: 2019-03-05T18:40:28Z
generateName: elasticsearch-
generation: 1
name: elasticsearch-9bgsr
namespace: openshift-operators
resourceVersion: "62004"
aggregationRule:
clusterRoleSelectors:
- matchLabels:
rbac.authorization.k8s.io/aggregate-to-cluster-reader: "true"
- matchLabels:
rbac.authorization.k8s.io/aggregate-to-view: "true"
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
annotations:
apiVersion: logging.openshift.io/v1alpha1
kind: ClusterLogging
metadata:
annotations:
io.openshift.clusterlogging.alpha/allinone: ""
creationTimestamp: 2019-01-09T16:40:56Z
generation: 1
name: example
namespace: openshift-logging
resourceVersion: "112581"
apiVersion: logging.openshift.io/v1alpha1
kind: Elasticsearch
metadata:
creationTimestamp: 2019-01-09T16:40:58Z
generation: 1
name: elasticsearch
namespace: openshift-logging
ownerReferences:
- apiVersion: logging.openshift.io/v1alpha1
controller: true
$ oc get deploy router-default -o yaml
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
annotations:
deployment.kubernetes.io/revision: "1"
creationTimestamp: 2018-12-12T21:33:40Z
generation: 1
labels:
app: router
@richm
richm / gist:4865049ba17bd946a3c84959ec017253
Last active December 10, 2018 23:34
python https client
import ssl
import httplib
import pprint
ctx = ssl.create_default_context(ssl.Purpose.CLIENT_AUTH, "/etc/pki/tls/certs/ca-bundle.crt")
ctx.verify_mode = ssl.CERT_OPTIONAL
c = httplib.HTTPSConnection("www.google.com:443", context=ctx)
c.request("GET", "/")
print c.getresponse().read()[:80]
E1128 22:29:02.134677 1 reflector.go:205] github.com/operator-framework/operator-lifecycle-manager/pkg/lib/queueinformer/queueinformer_operator.go:108: Failed to list *v1alpha2.OperatorGroup: the server could not find the requested resource (get operatorgroups.operators.coreos.com)