1. Install CentOS
2. Install dependencies
yum install -y epel-release yum install -y ansible python-cryptography python-crypto pyOpenSSL git docker
3. Install Openshift Ansible
git clone https://github.com/openshift/openshift-ansible
4. Create a new docker volume
Follow this tutorial: http://kumar-pravin.blogspot.de/2015/10/setting-up-storage-to-make-docker.html
5. Create Hosts file
Create the following file `vi openshift-hosts` and paste the following content:
[OSEv3:children] masters nodes etcd nfs [OSEv3:vars] ansible_ssh_user=root deployment_type=origin openshift_release=1.5.1 openshift_master_identity_providers=[{'name': 'htpasswd_auth', 'login': 'true', 'challenge': 'true', 'kind': 'HTPasswdPasswordIdentityProvider', 'filename': '/etc/origin/master/htpasswd'}] openshift_master_htpasswd_users={'admin': 'HASHEDPASSWORDHERE'} openshift_docker_disable_push_dockerhub=True openshift_master_default_subdomain=os.localdomain osm_default_node_selector='region=primary' osn_storage_plugin_deps=['nfs'] openshift_hosted_router_selector='region=primary' openshift_hosted_registry_selector='region=primary' openshift_override_hostname_check=false openshift_hosted_metrics_storage_kind=nfs openshift_hosted_metrics_storage_access_modes=['ReadWriteOnce'] openshift_hosted_metrics_storage_nfs_directory=/exports openshift_hosted_metrics_storage_nfs_options='*(rw,root_squash)' openshift_hosted_metrics_storage_volume_name=metrics openshift_hosted_metrics_storage_volume_size=40Gi [masters] os-master1 [etcd] os-master1 [nfs] os-master1 [nodes] os-master1 openshift_node_labels="{'region': 'primary', 'zone': 'default'}" openshift_schedulable=True
6. Create SSH key and upload add it to your known_hosts file
The next step is to enable SSH. Therefore, execute the following commands
ssh-keygen -t rsa -b 4096 -C "root@YOUR_SERVER.de" ssh-copy-id root@YOUR_SERVER_IP
7. Install Openshift
cd openshift-ansible ansible-playbook -i ../openshift-hosts playbooks/byo/config.yml
Thanks for nice and quick start for ALL-IN-ONE, i followed your instruction but config.yml is not available on below path
/openshift-hosts playbooks/byo/config.yml
Hey, I think this is due to the new version. According to this issue (https://github.com/openshift/openshift-ansible/issues/6503), I assume that they changed the workflow. I try to update it soon 🙂 But until then check out the new method the suggest in the issue. Hope that helps 🙂
Whats recommended way to install OPENSHIFT ORIGIN ALL-IN-ONE-SERVER with ANSIBLE where we are offline no access to internet? Download on other server and copy or any alternative?
I did not have this requirement. But my first try would be to prepare a server with internet connection and create e.g. an iso file that can be installed locally on the offline machines. Maybe also this link helps: https://docs.openshift.com/container-platform/3.5/install_config/install/disconnected_install.html
Can we extend ALL-IN-ONE-SERVER cluster. In my requirements i have to install on one server initially and after 3 months will get more hardware so i have to extend cluster on availability of further hardware.
Honestly, I did not try it. But I expect that you just have to add the additional hosts to the ansible hosts file as described in the advanced section of https://docs.openshift.com/enterprise/3.2/install_config/adding_hosts_to_existing_cluster.html. After that, you should be able to extend your cluster without reinstallation. I mean, the all in one server is in my opinion also only a hack that you have the normal installation with just one machine. The normal installation only have additional master nodes and can be extended as normal. Hope this helps 🙂