Last update: Tue Jan 14 23:15:49 UTC 2020 by @luckylittle
- Understand, identify, and work with containerization features
- Deploy a preconfigured application and identify crucial features such as namespaces, SELinux labels, and cgroups
############################################################# | |
# Run this script from the same location of the ign files # | |
############################################################# | |
########################## Installing govc ################################################# | |
# mkdir $HOME/bin | |
# cd $HOME/bin | |
# wget https:////github.com/vmware/govmomi/releases/download/v0.22.1/govc_linux_amd64.gz | |
# gunzip govc_linux_amd64.gz && mv govc_linux_amd64 govc && chmod +x govc |
PS: This method works just with BIOS | |
#Install packages# | |
sudo yum install git xz-devel -y | |
sudo yum groupinstall "Development tools" -y | |
#Download ipxe | |
git clone https://github.com/ipxe/ipxe/ | |
cd ipxe/src |
#!/bin/bash | |
IFS="," | |
CLUSTER_NAME=ocp | |
DOMAINNAME=example.com | |
BOOTSTRAP=192.168.150.30 | |
MASTERS=192.168.150.30,192.168.150.31,192.168.150.32 | |
WORKERS=192.168.150.40,192.168.150.41,192.168.150.42 |
oc patch configs.imageregistry.operator.openshift.io cluster --type merge --patch '{"spec":{"storage":{"emptyDir":{}}}}' | |
oc patch configs.imageregistry.operator.openshift.io/cluster --type merge --patch '{"spec":{"managementState": "Managed"}}' | |
cat > nfs.yaml << EOF | |
apiVersion: v1 | |
kind: PersistentVolume | |
metadata: | |
name: nfs-registry-storage | |
spec: |
#Create an Container Image with centos8 qcow2 | |
oc new-build --name centos8 --build-arg image_url=https://cloud.centos.org/centos/8/x86_64/images/CentOS-8-GenericCloud-8.1.1911-20200113.3.x86_64.qcow2 https://github.com/openshift-examples/cnv-container-disk-build.git | |
#Create Openshift Template | |
cat > apache-template.yaml << EOF | |
# Source: dist/templates/centos8-server-tiny.yaml | |
apiVersion: template.openshift.io/v1 | |
kind: Template |
oc new-app jenkins-ephemeral | |
or | |
oc new-app jenkins-persistent | |
Create a file dotnet-jenkins-slave.yaml with the below content: | |
kind: ConfigMap | |
apiVersion: v1 | |
metadata: | |
name: jenkins-agent-dotnet31 |
apiVersion: v1 | |
baseDomain: example.com | |
proxy: | |
httpProxy: http://<username>:<pswd>@<ip>:<port> | |
httpsProxy: http://<username>:<pswd>@<ip>:<port> | |
noProxy: example.com | |
compute: | |
- architecture: amd64 | |
hyperthreading: Enabled | |
name: worker |
Last update: Tue Jan 14 23:15:49 UTC 2020 by @luckylittle
## Install and Configure Image Registry Server | |
### List the devices and pick the correct one ( If you wanna have a disk dedicated to this ) | |
parted /dev/sdb --script mklabel gpt | |
parted /dev/sdb --script -- mkpart primary 0% 100% | |
partprobe pvcreate /dev/sdb1 | |
vgcreate registry /dev/sdb1 | |
lvcreate -l 100%FREE -n storage registry | |
mkfs.xfs /dev/registry/storage |
kind: ConfigMap | |
apiVersion: v1 | |
metadata: | |
name: proxy-env | |
namespace: quay-enterprise | |
data: | |
http_proxy: 'http://admin:[email protected]:8888' | |
https_proxy: 'http://admin:[email protected]:8888' | |
no_proxy: 'ralvares.local,172.30.0.0/16,192.168.0.0/16,10.0.0.0/8,localhost,127.0.0.1' | |
--- |