Skip to content

Instantly share code, notes, and snippets.

View weshayutin's full-sized avatar

Wesley Hayutin weshayutin

View GitHub Profile
@weshayutin
weshayutin / oadp1679.md
Last active May 15, 2023 12:23
OADP1679.md

highligts

backup w/ concurrent set to 1

NAMESPACE         NAME        PVC NAME   VOLUMESNAPSHOTCONTENT                              PHASE       BATCHINGSTATUS   AGE
minimal-8csivol   vsb-5qfqp              snapcontent-a63f52f6-8844-4423-ac1b-14a362300e98               Queued           54s
minimal-8csivol   vsb-6g6cz   volume1    snapcontent-f02aec31-a24a-4fa7-93c8-01c85d70947a   Completed   Completed        3m40s
minimal-8csivol   vsb-bgb5s   volume2    snapcontent-6762b80a-782e-4ad7-b612-67811e3387da   Completed   Completed        3m15s
minimal-8csivol   vsb-dzhwl   volume3    snapcontent-1e59ee85-69f0-42c1-ab72-990e5743d3d9   Completed   Completed        2m54s
minimal-8csivol   vsb-n2ld5              snapcontent-a8377d78-d965-450e-8547-819da3bdb5cb               Queued           9s
@weshayutin
weshayutin / clean_and_patch_finalizers.md
Last active June 27, 2023 21:06
clean_and_patch_finalizers.md

check setup

delete all backups

velero backup delete --all

volumeSnapShotClass

oc get volumeSnapShotClass -A  -o jsonpath='{range .items[*]}{"Name: "}{.metadata.name}{"  "}{"Retention Policy: "}{.deletionPolicy}{"\n"}{end}'

all restores from the same backup

restore #1

~ $ ls /mnt/volume1/
1683140886.txt  1683148730.txt  backup1         lost+found
~ $ ls /mnt/volume2
1683140886.txt  1683148730.txt  backup1         backup2         lost+found
~ $ ls /mnt/volume3
1683140886.txt  1683148730.txt  backup1         backup2         lost+found
@weshayutin
weshayutin / scan-ansible-archive for modules.py
Created July 15, 2021 20:33 — forked from cloudnull/scan-ansible-archive-for-modules.py
quick and dirty tool to scan an ansible archive and return a complete list of modules used throughout the archive.
import argparse
import collections
import os
import yaml
MODULES = collections.defaultdict(int)
POP_ITEMS = ['always',
'args',
@weshayutin
weshayutin / tripleo-repo-scraper.sh
Created December 8, 2020 21:06 — forked from cloudnull/tripleo-repo-scraper.sh
tripleo repo scraper
COMMIT_MSG="The lower constraint file has been removed
This file, and its tests, are not useful for tripleo so we're
removing because they're now becoming problematic."
git clone https://github.com/openstack/governance
pushd governance
python <<EOC
import yaml
@weshayutin
weshayutin / gist:3278df289fe5ac6c7bdeb4dc7a85f2c1
Created March 19, 2020 12:14
install tripleo from repos in ci
yum clean all
wget --content-disposition --no-parent -r https://logserver.rdoproject.org/openstack-component-network/opendev.org/openstack/tripleo-ci/master/periodic-tripleo-ci-centos-8-scenario010-standalone-network-master/5127081/logs/undercloud/etc/yum.repos.d/
mv logserver.rdoproject.org/openstack-component-network/opendev.org/openstack/tripleo-ci/master/periodic-tripleo-ci-centos-8-scenario010-standalone-network-master/5127081/logs/undercloud/etc/yum.repos.d/*.txt.gz .
for i in `ls *.gz`; do echo $i; gzip -d $i; done
for i in `ls *.txt`;do echo ${i::(-4)}; mv $i ${i::(-4)}; done
mkdir TEST
mv network-component.repo TEST/
yum repolist
https://my1.fr/blog/reviewing-puppet-openstack-patches/
https://opendev.org/ttygroup/gertty
https://paste.centos.org/view/d9b3437f
https://paste.centos.org/view/ad5bc1ef
@weshayutin
weshayutin / gist:692c80f2d4179dcf2108265bd9218bc9
Last active September 2, 2020 01:17
pull push containers for rdo manually
# clean everything
podman image prune -a
#Get a list of containers:
https://logserver.rdoproject.org/openstack-periodic-master/opendev.org/openstack/tripleo-ci/master/periodic-tripleo-centos-8-master-containers-build-push/940095c/logs/containers-expected-to-build.log
https://logserver.rdoproject.org/openstack-periodic-integration-main/opendev.org/openstack/tripleo-ci/master/periodic-tripleo-ci-build-containers-ubi-8-push/d18b100/logs/containers-successfully-built.log
cat containers-successfully-built.log | awk '{print $1}' | awk -F '[/]' '{ print $3}' > list_of_containers
pull containers:
@weshayutin
weshayutin / gist:c77a2aa33c0d7a4c9b93481dc2f789f4
Created January 13, 2020 17:56
sample script for promoting component/$name/consistent/delorean.repo to tripleo-ci-testing
#
set -e
source promoter_venv/bin/activate
source dlrnapi_secret
# Setup virtualenv for dlrnapi
: ${DLRNAPI_USERNAME:="ciuser"}
#: ${PROMOTE_TO:="${promotion_symlink}"}
@weshayutin
weshayutin / Search my gists.md
Created October 16, 2019 21:09 — forked from santisbon/Search my gists.md
How to search gists

Enter this in the search box along with your search terms:

Get all gists from the user santisbon.
user:santisbon

Find all gists with a .yml extension.
extension:yml

Find all gists with HTML files. language:html