Skip to content

Instantly share code, notes, and snippets.

View gregswift's full-sized avatar

Greg Swift gregswift

View GitHub Profile
vars:
organization:
name: My Organization
label: my_organization
locations:
- dc1
- dc2
katello_products:
- CentOS:
sync_plan: Weekly
@gregswift
gregswift / file lists
Last active October 22, 2020 12:00
barbican rpm spec
[greg5320@laptop noarch (master %=)]$ rpm -ql openstack-barbican
/etc/barbican/barbican-admin-paste.ini
/etc/barbican/barbican-api-paste.ini
/etc/barbican/barbican-api.conf
/etc/barbican/policy.json
/etc/logrotate.d/barbican-api
/usr/bin/barbican-db-manage.py
/usr/bin/barbican.sh
/usr/lib/systemd/system/openstack-barbican-api.service
/var/log/barbican
@gregswift
gregswift / proposed
Last active August 29, 2015 14:04
playbook,s roles, and tags oh my
---
- hosts: all
vars:
- port: 8080
roles:
- { role: plight, tags: ['disable'] }
tasks:
- name: Wait for all active connections to cease
wait_for: host=0.0.0.0 port={{ port }} state=drained exclude_hosts={{ exclude_hosts }}

Keybase proof

I hereby claim:

  • I am gregswift on github.
  • I am gregswift (https://keybase.io/gregswift) on keybase.
  • I have a public key whose fingerprint is 3C28 7598 463B 112B B86E 4587 0700 5D32 D126 1D69

To claim this, I am signing this object:

@gregswift
gregswift / wait_for_drain.py
Last active August 29, 2015 14:00
Standalone implementation of enhancement to ansible to add wait_for state=drained
import socket
import datetime
import time
import sys
import re
import binascii
HAS_PSUTIL = False
try:
import psutil
- vars_files:
- "vars/global_vars.yml"
- hosts: openstack-nodes
tasks:
- include: common/tasks/ssh_keys.yml user=root
- include: common/tasks/update.yml
- include: common/tasks/add_ops_repo.yml
- include: common/tasks/packages.yml
@gregswift
gregswift / ansible-authorized_key
Last active December 14, 2015 15:59
Implemented the option of providing an alternate location for a users authorized_key file. This can be useful if AuthorizedKeyFiles is changed in /etc/ssh/sshd_config
#!/usr/bin/python
# -*- coding: utf-8 -*-
"""
Ansible module to add authorized_keys for ssh logins.
(c) 2012, Brad Olson <[email protected]>
This file is part of Ansible
Ansible is free software: you can redistribute it and/or modify