Skip to content

Instantly share code, notes, and snippets.

View EmilyM1's full-sized avatar

Emily Moss EmilyM1

  • Santa Clara County, Calfornia - Mountain View
View GitHub Profile
@EmilyM1
EmilyM1 / Backport-risk-assessed
Created March 16, 2022 17:25
Label to backport 3.22
If the Bugzilla associated with the PR has the "FastFix" keyword, the subjective assessment on the issue has already been done and a customer is impacted. These PRs should be prioritized for merge.
verified
does not apply
The bug has significant impact either through severity, reduction in support, or number of users affected.
verified
@EmilyM1
EmilyM1 / gist:b0b4a401e6cc088dea8fd51d275c8062
Created February 2, 2022 22:46
Change of Audit Profile in Audit Logs
{
"kind": "Event",
"apiVersion": "audit.k8s.io/v1",
"level": "RequestResponse",
"auditID": "973373e8-3dac-4a8b-85be-dfd06cf71dd3",
"stage": "ResponseComplete",
"requestURI": "/apis/authorization.k8s.io/v1/subjectaccessreviews?timeout=10s",
"verb": "create",
"user": {
"username": "system:serviceaccount:openshift-apiserver:openshift-apiserver-sa",
Instructions to use:
Make namespace
Go to console, spin up Postgres (non-ephemeral) enter un, pw, db name
After it installs, this script will create secret, expose the service and echo the service url to copy to put into the CR
Then just install Metering
Note 1: I have the line to install Postgres without console in this script, just not sure if it works.
Note 2: I have an attempt at setting the clusterIP as an env var and injecting that into CR, it does not work so that's in and commented out also.
Feel free to improve this, even with the steps it does now, its quicker.
@EmilyM1
EmilyM1 / nfs_persistentvolume.yaml
Created July 13, 2020 19:56
NFS Server Deploy Resources
apiVersion: v1
kind: PersistentVolume
metadata:
name: nfs
labels:
role: nfs-server
spec:
capacity:
storage: 5Gi
accessModes:
@EmilyM1
EmilyM1 / Setting up Mysql and MeteringCR
Created June 10, 2020 18:53
Metastore Credentials
Create metastore secret in namespace. Username, password
Have mysql instance set up in namespace in cluster first. Use mysql 5.7, make note of db name.
Username, password, and secretName to match in all references throughout
Expose the service
oc -n <namespace> expose service mysql
grab the clusterIP with get
@EmilyM1
EmilyM1 / DI_Lunch
Last active November 20, 2019 18:51
Deploy,PV,PVC,Service
# minikube, apply vs create
# deploy ghost publishing platform
# maintain data at container startsand restarts mounts volume
# auto scale up cpu
apiVersion: extensions/v1beta1
kind: Deployment # rolls out replicaset
metadata:
name: ghost
spec: