Skip to content

Instantly share code, notes, and snippets.

View carlwgeorge's full-sized avatar

Carl George carlwgeorge

View GitHub Profile
#!/usr/bin/python
import click
import koji
import koji_cli.lib
import rpm
TAG='dist-c8-stream'
#!/usr/bin/bash
# parse elements of nvr
release=${nvr##*-}
[[ -n "$release" ]] || fail "error parsing release from $nvr"
nv=${nvr%-*}
[[ -n "$nv" ]] || fail "error parsing name-version from $nvr"
version=${nv##*-}
[[ -n "$version" ]] || fail "error parsing version from $nv"
name=${nv%-*}
#!/usr/bin/python
import re
import click
import koji
import requests
KEYID = '8483c65d'
import koji
import koji_cli.lib
profile = ''
scmurl = ''
build_target = ''
profile_module = koji.get_profile_module(profile)
session = profile_module.ClientSession(profile_module.config.server)
#!/usr/bin/bash
set -ue
name=$(basename $0)
utils_dir='/home/carl/sync/containers/utils'
if [[ "$name" == "run-image" ]]; then
echo "Don't run this directly, symlink it as the name you want to run."
exit 1
#!/usr/bin/bash
set -xeou pipefail
BASE_IMAGE=registry.fedoraproject.org/fedora
BASE_TAG=31
NAME=f$BASE_TAG
DNFARGS='--setopt install_weak_deps=0 --assumeyes'
# base image
#!/usr/bin/bash
set -xeou pipefail
DNFARGS='--setopt install_weak_deps=0 --assumeyes'
# base image
CONTAINER=$(buildah from --pull-always centos:8)
# utils
@carlwgeorge
carlwgeorge / yum-clean-all-demystified.md
Last active May 16, 2024 05:16
yum clean all demystified

TLDR:

  • yum clean all == clean most
  • rm -rf /car/cache/yum/* == really clean everything

From the man page:

Note that these commands only operate on files in currently enabled
repositories. If you use substitution variables (such as $releasever) in your cachedir configuration, the operation is further restricted to the current
values of those variables.

@carlwgeorge
carlwgeorge / gnome.yml
Last active April 8, 2025 10:18
ansible playbook for my gnome setup
# https://docs.ansible.com/ansible/latest/modules/dconf_module.html
#
# To determine what dconf keys and values to use, you can run `dconf watch /`
# in a terminal as you make changes in settings or tweaks. You can also use
# `dconf read <key>` and `dconf write <key> <value>` to experiment with various
# settings. The dconf-editor application is also useful for exploring various
# keys along with their descriptions.
- hosts: localhost
tasks:
@carlwgeorge
carlwgeorge / jwt-fails.txt
Last active November 5, 2018 03:49
PyJWT test failures
$ pytest-3 -v
========================================================= test session starts ==========================================================
platform linux -- Python 3.7.1, pytest-3.9.2, py-1.5.4, pluggy-0.7.1 -- /usr/bin/python3
cachedir: .pytest_cache
rootdir: /root/PyJWT-1.6.4, inifile:
collected 188 items
tests/test_algorithms.py::TestAlgorithms::test_algorithm_should_throw_exception_if_prepare_key_not_impl PASSED [ 0%]
tests/test_algorithms.py::TestAlgorithms::test_algorithm_should_throw_exception_if_sign_not_impl PASSED [ 1%]
tests/test_algorithms.py::TestAlgorithms::test_algorithm_should_throw_exception_if_verify_not_impl PASSED [ 1%]