ML
    • Recent
    • Categories
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Setup OKD (Origin Community Distribution) RedHat OpenShift FOSS distro on Centos 7

    IT Discussion
    okd centos openshift kubernetes
    2
    3
    521
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Emad RE
      Emad R
      last edited by Emad R

      Hi,

      Been time since I posted something... trying to find a job in Toronto, and not purchasing everything I see here.

      So this is an easy and insecure way to set it up in one server for testing and no need for FQDN. I highly recommend Vultr high freq VMs, at least the 24$ one with 4 GB RAM, the more the better.
      Start from latest Centos 7:

      yum update -y
      yum install -y epel-release
      yum install -y lsof glances net-tools htop nano yum-utils wget rsync git ncdu nload mc p7zip tuned iotop mdadm unzip iperf3 mlocate tree
      sed -i 's/SELINUX=enforcing/SELINUX=permissive/g' /etc/selinux/config
      sed -i 's/installonly_limit=5/installonly_limit=2/g' /etc/yum.conf
      timedatectl set-timezone Asia/Amman
      shutdown -r now
      yum clean all && yum autoremove
      
      sudo yum install -y yum-utils device-mapper-persistent-data lvm2
      sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
      sudo yum install -y  docker-ce docker-ce-cli containerd.io docker-compose
      
      sudo usermod -aG docker $USER
      newgrp docker
      
      sudo mkdir /etc/docker /etc/containers
      
      nano /etc/containers/registries.conf
      ---
      [registries.insecure]
      registries = ['172.30.0.0/16']
      ---
      
      nano /etc/docker/daemon.json
      ---
      {
         "insecure-registries": [
           "172.30.0.0/16"
         ]
      }
      ---
      
      sudo systemctl daemon-reload
      sudo systemctl restart docker
      sudo systemctl enable docker
      
      echo "net.ipv4.ip_forward = 1" | sudo tee -a /etc/sysctl.conf
      sudo sysctl -p
      
      firewall-cmd --permanent --delete-zone dockerc
      firewall-cmd --permanent --new-zone dockerc
      DOCKER_BRIDGE=`docker network inspect -f "{{range .IPAM.Config }}{{ .Subnet }}{{end}}" bridge`
      firewall-cmd --permanent --zone dockerc --add-source $DOCKER_BRIDGE
      firewall-cmd --permanent --zone dockerc --add-port=1-65535/udp
      firewall-cmd --permanent --zone dockerc --add-port=1-65535/tcp
      firewall-cmd --permanent --zone=public --add-port=1-65535/udp
      firewall-cmd --permanent --zone=public --add-port=1-65535/tcp
      firewall-cmd --reload
      systemctl restart firewalld
      
      wget https://github.com/openshift/origin/releases/download/v3.11.0/openshift-origin-client-tools-v3.11.0-0cbc58b-linux-64bit.tar.gz
      tar xvf openshift-origin-client-tools*.tar.gz
      cd openshift-origin-client*/
      sudo mv  oc kubectl  /usr/local/bin/
      oc version
      
      oc cluster up --public-hostname='SERVERPUBIP' --routing-suffix='SERVERPUBIP.xip.io'
      

      Thats it, be sure to replace

      • SERVERPUBIP with your Server Public IP

      • Asia/Amman and with your Timezone

      • Omit --- in nano commands, don't type those.

      Emad RE 1 Reply Last reply Reply Quote 1
      • Emad RE
        Emad R @Emad R
        last edited by

        Reserved for help and replies, remember to upvote.

        1 Reply Last reply Reply Quote 0
        • DustinB3403D
          DustinB3403
          last edited by

          The OKD GitHub page for additional details and the main website.

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          • First post
            Last post