Skip to content

Instantly share code, notes, and snippets.

View jasonbrooks's full-sized avatar

Jason Brooks jasonbrooks

View GitHub Profile
@jasonbrooks
jasonbrooks / centos8-to-stream-diff.txt
Created December 15, 2020 02:37
As of Dec 14 2020, CentOS 8 with all updates applied compared to CentOS Stream 8, package diffs.
-------------------------------------------------------------- ---------------------------------------------------------------
CentOS Linux 8 CentOS Stream 8
abattis-cantarell-fonts-0.0.25-4.el8.noarch
adwaita-cursor-theme-3.28.0-2.el8.noarch
adwaita-icon-theme-3.28.0-2.el8.noarch
atk-2.28.1-1.el8.x86_64
at-spi2-atk-2.26.2-1.el8.x86_64
at-spi2-core-2.28.0-1.el8.x86_64
authselect-1.2.1-2.el8.x86_64 authselect-1.2.2-1.el8.x86_64
authselect-libs-1.2.1-2.el8.x86_64 authselect-libs-1.2.2-1.el8.x86_64
[kubernetes]
name=Kubernetes
baseurl=https://packages.cloud.google.com/yum/repos/kubernetes-el7-x86_64
enabled=1
gpgcheck=1
repo_gpgcheck=1
gpgkey=https://packages.cloud.google.com/yum/doc/yum-key.gpg https://packages.cloud.google.com/yum/doc/rpm-package-key.gpg
exclude=kube*
<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<title>Red Hat Open Source Community</title>
<updated>2018-04-19T13:30:00+00:00</updated>
<author>
<name>Red Hat, Inc.</name>
</author>
<entry>
<title>Crafting an Open Source Product Strategy</title>
<link rel="alternate" href="http://community.redhat.com/blog/2018/04/crafting-an-open-source-product-strategy/"/>
@jasonbrooks
jasonbrooks / kubevirt-quickstart.md
Last active May 3, 2018 17:22
This is based on the kubevirt quickstart from https://github.com/kubevirt/demo/blob/master/README.md, with the addition of OpenShift steps and a note that while minikube is an easy way to bring up a cluster, these steps will work w/ other sorts of kubernetes and openshift clusters. If would make sense for this quickstart to live at https://www.k…

KubeVirt Quickstart

This demo will deploy KubeVirt on an existing Kubernetes (1.9 or later) or OpenShift Origin (3.9 or later) cluster. For a quick way to bring up a Kubernetes or OpenShift Origin cluster, see Minikube and Minishift.

Quickstart

Deploy KubeVirt

KubeVirt deploys as an add-on to a Kubernetes (1.9 or later) cluster, using the kubectl tool and the following manifest file:

Clone the openshift-ansible repo, check out the 3.9 branch.

# git clone https://github.com/openshift/openshift-ansible.git
# cd openshift-ansible
# git checkout release-3.9

Create an inventory, I'm calling it 2-node.yml, with contents like these, substituting your correct master and node hostnames:

#version=CentOS7
# Keyboard layouts
keyboard 'us'
# Reboot after installation
reboot
# Root password
rootpw --iscrypted --lock locked
# System language
lang en_US
user --name=none
@jasonbrooks
jasonbrooks / markdown-import.php
Last active December 16, 2017 02:03 — forked from vlucas/markdown-import.php
Imports Markdown files in a local directory into a WordPress installation
<?php
// Turn on all error reporting so we can see if anything goes wrong
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(-1);
// Relative path to your wp-config.php file (to connect to the database)
require '../../wp-config.php';
require './frontmatter.php'; // Parses YAML frontmatter - https://github.com/Modularr/YAML-FrontMatter
require './Parsedown.php'; // Markdown parser - https://github.com/erusev/parsedown

Fedora Atomic Host comes bundled with a version of Docker based on this project atomic repo that moves no faster than the upstream kubernetes project can abide. This means that Fedora Atomic pretty much always ships with an older version of docker than what's available from Docker Inc.

However, through the magic of rpm-ostree package layering, you can replace that older, baked-in docker with the very latest docker-ce. Here's how:

First, grab the repo file for docker-ce.

# cd /etc/yum.repos.d/
# curl -O https://download.docker.com/linux/fedora/docker-ce.repo

How to Migrate to Fedora 27 Atomic Kubernetes in System Containers

Starting with version 27 of Fedora Atomic Host, the rpms for Kubernetes, Flannel and Etcd are no longer "baked into" the image, but are available instead as system containers.

System containers can serve as drop-in replacements for components that had been included in the Fedora Atomic image. Once installed, these components will be manageable using the same systemctl commands that apply to regular rpm-installed components.

To replace Kubernetes, Flannel and Etcd with system containers, you would run the following commands.

System containers for master nodes

Start with CentOS 7

Set up the virt-sig repo:

# cat <<EOF > /etc/yum.repos.d/virt7-container-common-candidate.repo
[virt7-container-common-candidate]
name=virt7-container-common-candidate
baseurl=http://cbs.centos.org/repos/virt7-container-common-candidate/x86_64/os/
enabled=1