This guide will help you set up Knative using kind
(Kubernetes IN Docker) and get you started with Knative quickstarts.
- Docker
kind
(Kubernetes IN Docker)kubectl
[david@cainhurst redhat-openjdk-18-openshift-image]$ cekit-cache ls | |
Cached artifacts: | |
912c3cc4-7bd3-445d-9927-5063ba3b3bc1: | |
sha256: 04b95a87ee88e1cba7682884ea7f89d5ec097c0fa513e7aca1366d79fb3290a8 | |
sha1: 9cbe5393b6837849edbc067fe1a1405ff0c43605 | |
md5: f97f623e5b614a7b6d1eb5ff7158027b | |
names: | |
hawkular-javaagent-1.0.1.Final-redhat-2-shaded.jar | |
d9171217-744e-43af-8d2f-5ee04f2fd741: | |
sha256: 223d394c3912028ddd18c6401b3aa97fe80e8d0ae3646df2036d856f35f18735 |
In this lab we are going to deploy 2 custom made applications on OpenShift:
demo-color-api - serves as a public facing app
demo-color-backend - serves data to demo-color-api
We will show you how to deploy these application on OpenShift, how to use Jenkins
from pyroute2 import IPDB, IPRoute | |
import os | |
def create_veth_path(fd): | |
ip = IPDB() | |
# create interface pair | |
ip.create(ifname='pycoz0', kind='veth', peer='pycoz1').commit() | |
ip.release() | |
setup_ip('pycoz0', '10.0.0.1/24') |
import os | |
groups_types = {'cpu': '/sys/fs/cgroup/cpu/system.slice/', | |
'memory': '/sys/fs/cgroup/memory/system.slice/'} | |
def create_cgroups(name): | |
for group, path in groups_types.items(): | |
if os.path.exists(path): | |
target = os.path.join(path, name) |
# goo.gl/bRsdYQ | |
import ctypes | |
import os | |
from multiprocessing import Process | |
CLONE_NEWUSER = 0x10000000 | |
CLONE_NEWPID = 0x20000000 | |
CLONE_NEWNET = 0x40000000 |
# please run: mkdir /tmp/img ; docker export $(docker create centos) | tar -C /tmp/img/ -xvf - | |
# before this script | |
import os | |
import ctypes | |
from multiprocessing import Process | |
CLONE_NEWUSER = 0x10000000 | |
CLONE_NEWPID = 0x20000000 |