Skip to content

Instantly share code, notes, and snippets.

View waynedovey's full-sized avatar
🎯
Focusing

Wayne Dovey waynedovey

🎯
Focusing
View GitHub Profile
@waynedovey
waynedovey / oauth-htpasswd.yaml
Created February 19, 2023 22:11
oauth-htpasswd.yaml
apiVersion: config.openshift.io/v1
kind: OAuth
metadata:
name: cluster
spec:
identityProviders:
- name: my_htpasswd_provider
mappingMethod: claim
type: HTPasswd
htpasswd:
@waynedovey
waynedovey / install-config.yaml
Last active February 19, 2023 21:29
install-config.yaml
apiVersion: v1
baseDomain: sandbox.acme.com
compute:
- name: worker
hyperthreading: Enabled
replicas: 0
controlPlane:
name: master
replicas: 1
architecture: amd64
podman pull registry.redhat.io/advanced-cluster-security/rhacs-main-rhel8:3.72.1
podman tag registry.redhat.io/advanced-cluster-security/rhacs-main-rhel8:3.72.1 quay.io/wdovey/advanced-cluster-security/rhacs-main-rhel8:3.72.1
podman push --remove-signatures quay.io/wdovey/advanced-cluster-security/rhacs-main-rhel8:3.72.1
podman pull registry.redhat.io/advanced-cluster-security/rhacs-scanner-rhel8:3.72.1
podman tag registry.redhat.io/advanced-cluster-security/rhacs-scanner-rhel8:3.72.1 quay.io/wdovey/advanced-cluster-security/rhacs-scanner-rhel8:3.72.1
podman push --remove-signatures quay.io/wdovey/advanced-cluster-security/rhacs-scanner-rhel8:3.72.1
podman pull registry.redhat.io/advanced-cluster-security/rhacs-scanner-db-rhel8:3.72.1
podman tag registry.redhat.io/advanced-cluster-security/rhacs-scanner-db-rhel8:3.72.1 quay.io/wdovey/advanced-cluster-security/rhacs-scanner-db-rhel8:3.72.1
# managedclustersetbinding.yaml
cat << EOF | oc apply -f -
apiVersion: cluster.open-cluster-management.io/v1alpha1
kind: ManagedClusterSetBinding
metadata:
name: production-clusters
namespace: openshift-gitops
spec:
clusterSet: production-clusters
EOF
@waynedovey
waynedovey / mysql-deployment.yaml
Last active October 1, 2022 07:09 — forked from p4tin/README.md
Wordpress Kubernetes Cluster
apiVersion: apps/v1
kind: Deployment
metadata:
name: wordpress-mysql
labels:
app: wordpress
spec:
selector:
matchLabels:
app: wordpress
#!/bin/bash
_NAMESPACE="nfs-external-provisioner"
oc new-project ${_NAMESPACE}
oc adm policy add-scc-to-user hostmount-anyuid \
-n ${_NAMESPACE} \
-z nfs-subdir-external-provisioner
<-- cr-main.yaml --->
apiVersion: psmdb.percona.com/v1-10-0
kind: PerconaServerMongoDB
metadata:
name: sydney-cluster
spec:
unmanaged: false
crVersion: 1.10.0
image: percona/percona-server-mongodb:4.4.6-8
apiVersion: machine.openshift.io/v1beta1
kind: MachineSet
metadata:
annotations:
machine.openshift.io/GPU: "0"
machine.openshift.io/memoryMb: "16384"
machine.openshift.io/vCPU: "4"
labels:
hive.openshift.io/machine-pool: master
hive.openshift.io/managed: "true"
@waynedovey
waynedovey / scaledown.sh
Last active November 7, 2023 14:28
Scale Down OpenShift Monitoring
oc patch clusterversion/version --type='merge' -p "$(cat <<- EOF
spec:
overrides:
- group: apps/v1
kind: Deployment
name: cluster-monitoring-operator
namespace: openshift-monitoring
unmanaged: true
EOF
)"
oc edit machinesets ocp4-lbvrr-worker -n openshift-machine-api
resourcepool: /DC/host/cluster/Resources
workspace:
datacenter: DC