Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
systemctl restart crio
systemctl restart cc-proxy
kubeadm init --pod-network-cidr 10.244.0.0/16 && export KUBECONFIG=/etc/kubernetes/admin.conf
echo -n "Starting flannel..."
sleep 5
diff --git a/cmd/ocic/container.go b/cmd/ocic/container.go
index e4fe4cd..57c575f 100644
--- a/cmd/ocic/container.go
+++ b/cmd/ocic/container.go
@@ -1,14 +1,19 @@
package main
import (
+ "bufio"
"fmt"

This page describes how to run Kubernetes on top of Clear Containers 2.1

Kubernetes

Kubernetes is a Google project and the dominant container orchestration engine.

Kubernetes clusters run containers pods. Inside a pod, all containers share the pod resources (networking, storage, etc...) and all pods within a cluster have their own IP address.

By default Kubernetes runs the full Docker stack to start pods and containers within a pod. Rkt is an alternative container runtime for Kubernetes.

Problem Statement

---
apiVersion: v1
kind: ServiceAccount
metadata:
name: flannel
namespace: kube-system
---
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRoleBinding
metadata:

Clone OpenShift

mkdir -p $GOPATH/src/github.com/openshift
cd $GOPATH/src/github.com/openshift/
git clone git://github.com/sameo/origin

Build OpenShift

Install FC25 server

Password less root ssh

dnf install git ansible

git clone https://github.com/runcom/openshift-origin-cri-o

git clone https://github.com/openshift/openshift-ansible

#!/bin/bash
printf "Clearing COR logs..."
rm -rf /var/run/cc-oci-runtime/cc-oci-runtime.log
printf "Done\n"
printf "Killing all Docker containers..."
docker rm -f $(sudo docker ps -a -q) 2> /dev/null
printf "Done\n"
{
"cniVersion": "0.2.0",
"name": "mynet",
"type": "bridge",
"bridge": "cni0",
"isGateway": true,
"ipMasq": true,
"ipam": {
"type": "host-local",
"subnet": "10.88.0.0/16",
{
"cniVersion": "0.2.0",
"type": "loopback"
}
apiVersion: v1
kind: Pod
metadata:
annotations:
io.kubernetes.cri-o.trusted: "true"
name: nginx-trusted
spec:
containers:
- name: nginx
image: sameo/nginx-kubecon:1.0