Skip to content

Instantly share code, notes, and snippets.

View jarrpa's full-sized avatar

Jose A. Rivera jarrpa

  • Red Hat
  • Saint Paul, MN
View GitHub Profile
apiVersion: ocs.openshift.io/v1
kind: StorageCluster
metadata:
annotations:
uninstall.ocs.openshift.io/cleanup-policy: delete
uninstall.ocs.openshift.io/mode: graceful
name: ocs-storagecluster
namespace: openshift-storage
spec:
allowRemoteStorageConsumers: true
@jarrpa
jarrpa / install-config-aws.yaml
Created September 26, 2022 18:45
openshift-installer AWS config
apiVersion: v1
baseDomain: ocs.syseng.devcluster.openshift.com
compute:
- architecture: amd64
hyperthreading: Enabled
name: worker
platform:
aws:
type: m4.xlarge
replicas: 3
$SSHAgentSvc = Get-Service -Name ‘ssh-agent’
Set-Service -Name $SSHAgentSvc.Name -StartupType Automatic
Start-Service -Name $SSHAgentSvc.Name
ssh-add
Get-Content -Path $HOME\.ssh\id_rsa.pub | Set-Clipboard
Start-Process ‘https://github.com/settings/ssh/new'
choco install git -y
$SSHPath = (Get-Command -Name ‘ssh.exe’).Source
@jarrpa
jarrpa / go-module-rename.sh
Created April 21, 2022 16:10
go-module-rename.sh
#!/bin/bash
set -e
OLD_NAME="${1}"
NEW_NAME="${2}"
go mod edit -module ${NEW_NAME}
find . -type f -name '*.go' \
diff --git a/services/provider/server/server.go b/services/provider/server/server.go
index 17a83900..a0d67bca 100644
--- a/services/provider/server/server.go
+++ b/services/provider/server/server.go
@@ -280,7 +280,11 @@ func (s *OCSProviderServer) getExternalResources(ctx context.Context, consumerRe
// Get mgr pod hostIP
podList := &corev1.PodList{}
- err = s.client.List(ctx, podList, client.MatchingLabels(map[string]string{"app": "rook-ceph-mgr"}))
+ listOpts := []client.ListOption{
@jarrpa
jarrpa / dd-pv.sh
Created September 25, 2021 22:16
a good dd cmd
#!/bin/bash
# e.g. ~500GB = 500107862016
BYTES="${1}"
dd if=/dev/sdb | pv -pterbas "${BYTES}" | dd of=/dev/dsf bs=4096
apiVersion: v1
kind: Pod
metadata:
creationTimestamp: 2018-06-29T18:10:54Z
generateName: demo-0-6c84b49cc4-
labels:
anthill: demo-node
demo: gluster-node
glusterfs-node: demo-0.demo
name: demo-0
// ==UserScript==
// @name Trello Red Hat Bugzilla Integration
// @namespace http://jarrpa.net
// @version 0.4
// @require http://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js
// @description Looks for card titles with 'Bug \d+' and adds badge/links to bugzilla. Also autocompletes card titles that contain 'Bug \d+' from bugzilla. Autocomplete is actived when pressing `:` after 'Bug \d+'. Originally based on https://github.com/cmadsen/TrelloBugzilla
// @match https://trello.com/*
// @copyright 2012+, Carsten Madsen and Luke Brooker
// @copyright 2014, Jose A. Rivera
// @grant GM_xmlhttpRequest