Skip to content

Instantly share code, notes, and snippets.

View maxamillion's full-sized avatar

Adam Miller maxamillion

View GitHub Profile

Keybase proof

I hereby claim:

  • I am maxamillion on github.
  • I am maxamillion (https://keybase.io/maxamillion) on keybase.
  • I have a public key whose fingerprint is 057A 09D9 E5B1 F1E8 19DC 0B49 3911 1BEF 655D DEDD

To claim this, I am signing this object:

@maxamillion
maxamillion / osbs_notes.md
Last active September 1, 2015 16:49
OSBS + OpenShift notes (dedicated OpenShift to build system)

#NOTES:

  • atomic-reactor and osbs from my COPR my COPR (latest from upstream git)
  • openshift-ansible upstream for installation of OpenShift
  • for "lab environment" DNS setup, use dnsmasq OpenShift docs
    • The example here is a single-node deployment named lsobs.example.com with the *.cloudapps.example.com configured as in the doc
  • Turns out you don't need a fully functional OpenShift environment to run OSBS
    • Can work without openshift-router and openshift-docker-registry
  • Probably not best
@maxamillion
maxamillion / osbs_notes_multitenant.md
Created July 31, 2015 19:22
OSBS + OpenShift Notes (namespaced and multi-tenant)

#NOTES:

  • atomic-reactor and osbs from my COPR my COPR (latest from upstream git)
  • openshift-ansible upstream for installation of OpenShift
  • for "lab environment" DNS setup, use dnsmasq OpenShift docs
    • The example here is a single-node deployment named lsobs.example.com with the *.cloudapps.example.com configured as in the doc
  • Turns out you don't need a fully functional OpenShift environment to run OSBS
    • Can work without openshift-router and openshift-docker-registry
  • Probably not best
@maxamillion
maxamillion / osbs_notes_v2.md
Last active November 2, 2016 21:28
osbs_notes_v2.md

#Notes for OSBS with Docker Registry V2

Pre-Reqs

Build atomic-reactor dev

## If you have not done this already, clone the git repository
## (need my fork for Fedora build fixes until merged upstream)
$ git clone https://github.com/maxamillion/atomic-reactor.git
$ git checkout build
@maxamillion
maxamillion / openshiftv3fedora24.rst
Last active July 28, 2016 18:13
OpenShift v3 Bring Your Own Fedora 24 Hosts

OpenShift v3 Bring Your Own Fedora 24 Hosts

This is meant to be an evolution of the old Bring Your Own Host document that has been retired upstream. The aim is to be a simple step by step guide for setting up a multi host environment

Example inventory we will be working from can be found upstream here.

@maxamillion
maxamillion / fact_template.j2
Created December 19, 2018 15:30
Ansible filtering facts with templates instead of json_query filter
{% set results = {} %}
{% for fact in ansible_facts %}
{% if ansible_facts[fact] is mapping and 'pciid' in ansible_facts[fact] %}
{% set x=results.__setitem__(ansible_facts[fact]['pciid'], ansible_facts[fact]['device']) %}
{% endif %}
{% endfor %}
{{ results|to_json}}
@maxamillion
maxamillion / plugin.out.json
Last active March 18, 2019 15:21
gce.py Script vs gcp_compute.py Plugin
{
"_meta": {
"hostvars": {
"104.196.66.112": {
"cpuPlatform": "Intel Haswell",
"creationTimestamp": "2017-11-02T15:56:44.318-07:00",
"deletionProtection": true,
"disks": [
{
"autoDelete": true,
@maxamillion
maxamillion / dnf_prep_transaction.py
Created April 4, 2019 21:32
Prep DNF Transaction (order matters)
#!/usr/bin/python3
import dnf
base = dnf.Base()
base.conf.read()
base.read_all_repos()
#base.init_plugins()
#base.pre_configure_plugins()
#base.configure_plugins()
base.fill_sack()
base.read_comps()
@maxamillion
maxamillion / gist:679e8950df0bd2cbf564ee9835b62d55
Last active June 12, 2019 03:27
QRadar CE on CentOS 7.6+ Hacks and Workarounds (so far...)
# Hacks to work around the broken installer and incompatible bundled rpms
mkdir /media/cdrom
mount -o loop ~/QRadarCE7_3_1.GA.iso /media/cdrom
mkdir /tmp/qradar-7.6
cp -R /media/cdrom/* /tmp/qradar-7.6
sed -i 's/release 7.5/release 7.6/g' /tmp/qradar-7.6/inc/setup.funcs
cat >/etc/yum/pluginconf.d/priorities.conf <<EOF
[main]
@maxamillion
maxamillion / gist:da61f47dc23c3a7f81fff0d84e02e97f
Created August 1, 2019 20:40
httpapi can't determine network_os with multiple plays in a playbook
INVENTORY.TXT
[snort]
40.121.40.224
168.62.170.199
[qradar]
#ec2-34-217-52-111.us-west-2.compute.amazonaws.com
13.90.249.151