This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| rm -f out ; mkfifo out ; trap "rm -f out" EXIT ; while true ; do cat out | nc -l 1500 > >(export REQUEST= ; while read line ; do line=$(echo "$line" | tr -d '[\r\n]') ; if echo "$line" | grep -qE '^GET /' ; then REQUEST=$(echo "$line" | cut -d ' ' -f2) ; elif [ "x$line" = x ] ; then HTTP_200="HTTP/1.1 200 OK" ; HTTP_LOCATION="Location:" ; HTTP_404="HTTP/1.1 404 Not Found" ; if echo $REQUEST | grep -qE '^/echo/' ; then printf "%s\n%s %s\n\n%s\n" "$HTTP_200" "$HTTP_LOCATION" $REQUEST ${REQUEST#"/echo/"} > out ; elif echo $REQUEST | grep -qE '^/date' ; then date > out ; elif echo $REQUEST | grep -qE '^/stats' ; then vmstat -S M > out ; elif echo $REQUEST | grep -qE '^/net' ; then ifconfig > out ; else printf "%s\n%s %s\n\n%s\n" "$HTTP_404" "$HTTP_LOCATION" $REQUEST "Resource $REQUEST NOT FOUND!" > out ; fi ; fi ; done) ; done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #14 changing the route for the MS1 with gwipaddress with documentation ubuntu ICN dockerhub and eth0 fix with centos | |
| docker rmi integratedcloudnative/ovn-images:centos-v2.2.0 && \ | |
| pushd utilities/docker && \ | |
| docker build --no-cache --rm -t integratedcloudnative/ovn-images:centos-v2.2.0 . -f centos/Dockerfile && \ | |
| popd && \ | |
| docker push integratedcloudnative/ovn-images:centos-v2.2.0 | |
| #15 changing the route for the MS1 with gwipaddress with documentation ubuntu ICN dockerhub and eth0 fix with centos | |
| docker rmi integratedcloudnative/ovn4nfv-k8s-plugin:centos-v2.2.0 && \ | |
| docker build --no-cache --rm -t integratedcloudnative/ovn4nfv-k8s-plugin:centos-v2.2.0 . -f build/Dockerfile.centos && \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo apt-get remove docker docker-engine docker.io containerd runc && \ | |
| sudo apt-get update && \ | |
| sudo apt-get install apt-transport-https ca-certificates curl gnupg-agent software-properties-common -y && \ | |
| curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - && \ | |
| sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" && \ | |
| sudo apt-get update && \ | |
| sudo apt-get install docker-ce docker-ce-cli containerd.io -y && \ | |
| sudo docker run hello-world | |
| sudo apt-get update && sudo apt-get install -y apt-transport-https curl && \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- | |
| kind: Service | |
| apiVersion: v1 | |
| metadata: | |
| name: ovn-nb-tcp | |
| namespace: kube-system | |
| spec: | |
| ports: | |
| - name: ovn-nb-tcp | |
| protocol: TCP |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| kubectl create ns metal3 | |
| kubectl create -f https://github.com/metal3-io/baremetal-operator/blob/master/deploy/crds/metal3_v1alpha1_baremetalhost_crd.yaml | |
| cat <<EOF | kubectl create -f - | |
| apiVersion: v1 | |
| items: | |
| - apiVersion: metal3.io/v1alpha1 | |
| kind: BareMetalHost | |
| metadata: | |
| annotations: | |
| kubectl.kubernetes.io/last-applied-configuration: | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Create the `system:kube-apiserver-to-kubelet` [ClusterRole](https://kubernetes.io/docs/admin/authorization/rbac/#role-and-clusterrole) with permissions to access the Kubelet API and perform most common tasks associated with managing pods: | |
| ``` | |
| cat <<EOF | kubectl apply --kubeconfig admin.kubeconfig -f - | |
| apiVersion: rbac.authorization.k8s.io/v1beta1 | |
| kind: ClusterRole | |
| metadata: | |
| annotations: | |
| rbac.authorization.kubernetes.io/autoupdate: "true" | |
| labels: |