浏览代码

add examples

Michael Gugino 6 年之前
父节点
当前提交
798c5e36b9
共有 3 个文件被更改,包括 71 次插入0 次删除
  1. 17 0
      README.md
  2. 24 0
      inventory/40_basic_inventory.ini
  3. 30 0
      inventory/install-config-example.yml

+ 17 - 0
README.md

@@ -97,6 +97,22 @@ Install the new installer from https://www.github.com/openshift/installer
 Construct a proper install-config.yml, and make a copy called
 Construct a proper install-config.yml, and make a copy called
 install-config-ansible.yml.
 install-config-ansible.yml.
 
 
+## Hosts
+You will need the following hosts
+
+### Boostrap host
+This is a special host that is not part of the cluster but is required to be
+available to help the cluster bootstrap itself.  This is not a bastion host,
+it will initially be part of the cluster and should be able to communicate with
+the masters in the cluster.
+
+### Masters
+You need 1 or 3 masters.
+
+### Workers
+You need 0 or more workers.  Note, by default, masters are unschedulable so
+you will need one or more workers if you want to schedule workloads.
+
 ## DNS
 ## DNS
 4.x installs require specific dns records to be in place, and there is no way
 4.x installs require specific dns records to be in place, and there is no way
 to complete an install without working DNS.  You are in charge of ensuring the
 to complete an install without working DNS.  You are in charge of ensuring the
@@ -113,6 +129,7 @@ install-config.yml value of 'baseDomain' must be a working domain.
 <clustername>-api.<baseDomain> # ex: mycluster-api.example.com
 <clustername>-api.<baseDomain> # ex: mycluster-api.example.com
 <clustername>-master-0.<baseDomain> # ex: mycluster-master-0.example.com
 <clustername>-master-0.<baseDomain> # ex: mycluster-master-0.example.com
 <clustername>-etcd-0.<baseDomain> # ex: mycluster-etcd-0.example.com
 <clustername>-etcd-0.<baseDomain> # ex: mycluster-etcd-0.example.com
+<clustername>-bootstrap.<baseDomain> # ex: mycluster-bootstrap.example.com
 ```
 ```
 
 
 Note: There should be a master/etcd record for each master host in your cluster
 Note: There should be a master/etcd record for each master host in your cluster

+ 24 - 0
inventory/40_basic_inventory.ini

@@ -0,0 +1,24 @@
+[nodes:children]
+bootstrap
+masters
+workers
+
+[nodes:vars]
+ansible_ssh_user=centos
+ansible_become=True
+
+openshift_install_config_path="~/install-config-ansible.yml"
+openshift_deployment_type=origin
+openshift_release=v4.0
+
+[bootstrap]
+mycluster-bootstrap.example.com
+
+[bootstrap:vars]
+openshift_ignition_file_path="~/bootstrap.ign"
+
+[masters]
+mycluster-master-0.example.com
+
+[workers]
+mycluster-worker-0.example.com

+ 30 - 0
inventory/install-config-example.yml

@@ -0,0 +1,30 @@
+---
+baseDomain: example.com
+machines:
+- name: master
+  replicas: 1
+- name: worker
+  # This should always be zero for openshift-ansible
+  replicas: 0
+metadata:
+  name: mycluster
+networking:
+  clusterNetworks:
+  - cidr: 10.128.0.0/14
+    hostSubnetLength: 9
+  serviceCIDR: 172.30.0.0/16
+  type: OpenshiftSDN
+platform:
+  libvirt:
+    # This URI is not actually used
+    URI: null
+    defaultMachinePlatform:
+      image: file:///unused
+    masterIPs: null
+    network:
+      if: null
+      ipRange: null
+pullSecret: |
+  < paste your pullSecret here >
+sshKey: |
+  < paster your pubkey here >