Skip to content

Instantly share code, notes, and snippets.

View chornberger-c2c's full-sized avatar

Christopher Hornberger chornberger-c2c

View GitHub Profile
@chornberger-c2c
chornberger-c2c / rh-satellite-errata.yml
Last active December 22, 2023 09:23
Red Hat Satellite - Errata and Packages
---
- hosts: all
vars:
satellite_fqdn: satellite.local
satellite_port: 443
satellite_user: admin
satellite_password: changeme
@chornberger-c2c
chornberger-c2c / sat6RepositorySets.sh
Last active July 21, 2023 10:19
Red Hat Satellite - Repository Sets
#!/bin/bash
usage() {
cat <<EOF
Override repositories per host on a Satellite server
Usage: $0
-s, --server Satellite server
-u, --user username on Satellite server
@chornberger-c2c
chornberger-c2c / sat6ShowHosts.sh
Last active December 14, 2022 12:04
Satellite 6 - list all hosts and their IDs
#!/bin/bash
usage() {
cat <<EOF
Usage: $0 -s server -u user -p pass
Lists host names and host IDs registered to a Satellite Server in CSV format
EOF
exit 0
}
@chornberger-c2c
chornberger-c2c / sat6ShowHostSubscriptions.py
Last active April 24, 2025 14:10 — forked from sideangleside/sat6ShowHostPackages.py
Red Hat Satellite - List Subscriptions
#!/usr/bin/env python
# File: sat6ShowHostSubscriptions.py
# Authors: Rich Jerrido <[email protected]>
# Christopher Hornberger <[email protected]>
#
# Purpose: given an hostname and login to Satelite, show me all the
# hosts and their subscriptions.
#
# This program is free software; you can redistribute it and/or modify
@mjf
mjf / haproxy-postgres-binary-checks.cfg
Last active October 24, 2023 15:09
HAProxy TCP Binary Check for Postgres Replica Instance
# HAProxy TCP Binary Check for Postgres Replica Instance
# Copyright (C) "2021" Matous Jan Fialka, <https://mjf.cz/>
# Released under the terms of "The MIT License"
# https://www.postgresql.org/docs/current/protocol-message-formats.html
backend postgres
bind :5432
@jmariondev
jmariondev / fedora-coreos-ansible.yaml
Last active November 3, 2024 20:47
Run Ansible on Fedora CoreOS (Without rpm-ostree reboot!)
---
- hosts: all
become: true
# We may not have python3 on FCOS, so don't gather facts yet. We will make
# sure Python is installed first then explicitly gather facts later.
gather_facts: false
pre_tasks:
# If the host doesn't have python3 + the docker and selinux modules,
# this will fail. failed_when swallows the error but we can later use
# the return code to decide to try installing these dependencies.
@arkady-emelyanov
arkady-emelyanov / haproxy.cfg
Last active October 25, 2023 22:02
haproxy check: postgresql is master
# Sample haproxy postgresql master check
#
# haproxy listen: 5431
# pg, instance #1 listen: 5432 (master node)
# pg, instance #2 listen: 5433 (replica node)
# external failover, promoting replica to master in case of failure
# passwordless auth for user web
# template1 database is accessible by user web
#
# haproxy will pass connection to postgresql master node:
@miticojo
miticojo / satellite_6.2_api_collection.md
Last active September 12, 2024 11:43
Satellite 6.2 API Resouce Collection
{
  "links": {
  "base": {},
  "api": {},
  "host_subscriptions": {
  "List a host's subscriptions": "/api/hosts/:host_id/subscriptions",
  "Trigger an auto-attach of subscriptions": "/api/hosts/:host_id/subscriptions/auto_attach",
  "List subscription events for the host": "/api/hosts/:host_id/subscriptions/events",
  "Unregister the host as a subscription consumer": "/api/hosts/:host_id/subscriptions",
@fvanderbiest
fvanderbiest / gist:f5d5e467c7ca004ce73b
Created May 2, 2014 06:45
geoserver reload script
#!/usr/bin/env python
#-*- coding: utf-8 -*-
"""This is a script that we use to reload geoserver catalogs when load balancing them"""
"""
Copyright 2014 Camptocamp. All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are
permitted provided that the following conditions are met: