Last active
February 26, 2021 04:46
-
-
Save camilamacedo86/eed13de4e31aa411dec9daf11f528bcb to your computer and use it in GitHub Desktop.
[OpenShift] - Example of [OSEv3:vars] in the inventory file to setup 3.11 enterprise version with Operator Framework
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
[OSEv3:vars] | |
########################################################################### | |
### Ansible Vars | |
########################################################################### | |
timeout=60 | |
ansible_user=user | |
ansible_become=yes | |
########################################################################### | |
### OpenShift Basic Vars | |
########################################################################### | |
openshift_deployment_type=openshift-enterprise # Type of installation it could be the ODK | |
openshift_disable_check="disk_availability,memory_availability,docker_image_availability" | |
# OpenShift Version: | |
openshift_image_tag=v3.11.16 | |
openshift_pkg_version=-3.11.16 | |
openshift_release=3.11.16 | |
# Node Groups | |
openshift_node_groups=[{'name': 'node-config-master', 'labels': ['node-role.kubernetes.io/master=true','runtime=docker']}, {'name': 'node-config-infra', 'labels': ['node-role.kubernetes.io/infra=true','runtime=docker']}, {'name': 'node-config-compute', 'labels': ['node-role.kubernetes.io/compute=true','runtime=docker'], 'edits': [{ 'key': 'kubeletArguments.pods-per-core','value': ['20']}]}] | |
# Configure logrotate scripts | |
# See: https://github.com/nickhammond/ansible-logrotate | |
logrotate_scripts=[{"name": "syslog", "path": "/var/log/cron\n/var/log/maillog\n/var/log/messages\n/var/log/secure\n/var/log/spooler\n", "options": ["daily", "rotate 7","size 500M", "compress", "sharedscripts", "missingok"], "scripts": {"postrotate": "/bin/kill -HUP `cat /var/run/syslogd.pid 2> /dev/null` 2> /dev/null || true"}}] | |
# Deploy Operator Lifecycle Manager Tech Preview | |
# See more about it here: https://docs.openshift.com/container-platform/3.11/install/configuring_inventory_file.html#configuring-the-operator-lifecycle-manager | |
openshift_enable_olm=true | |
########################################################################### | |
### OpenShift Registries Locations | |
########################################################################### | |
# Before it was registry.access.redhat.com | |
# The previus registry still working but deprecated with the version 3.11 indeed published. RedHat is using now registry.redhat.io | |
oreg_url=registry.redhat.io/openshift3/ose-${component}:${version} | |
oreg_auth_user=REPLACE_ME | |
oreg_auth_password=REPLACE_ME | |
# For Operator Framework Images | |
openshift_additional_registry_credentials=[{'host':'registry.connect.redhat.com','user':'REPLACE_ME','password':'REPLACE_ME','test_image':'mongodb/enterprise-operator:0.3.2'}] | |
openshift_examples_modify_imagestreams=true | |
# Set this line to enable NFS | |
openshift_enable_unsupported_configurations=True | |
########################################################################### | |
### OpenShift Master Vars | |
########################################################################### | |
openshift_master_api_port=8443 | |
openshift_master_console_port=8443 | |
openshift_master_cluster_hostname=loadbalancer.myhost.com | |
openshift_master_cluster_public_hostname=loadbalancer.myhost.example.com | |
openshift_master_default_subdomain=apps.myhost.example.com | |
openshift_master_overwrite_named_certificates=True | |
########################################################################### | |
### OpenShift Network Vars | |
########################################################################### | |
osm_cluster_network_cidr=10.1.0.0/16 | |
openshift_portal_net=172.30.0.0/16 | |
# The following defined the type of SDN plugin which could be for example 'redhat/openshift-ovs-networkpolicy' | |
# See more about it here: https://docs.openshift.com/container-platform/3.11/install_config/configuring_sdn.html | |
os_sdn_network_plugin_name='redhat/openshift-ovs-subnet' | |
########################################################################### | |
### OpenShift Authentication Vars | |
########################################################################### | |
# See more about authenricantion providers here: https://docs.openshift.com/container-platform/3.11/install_config/configuring_authentication.html | |
openshift_master_htpasswd_file=/root/htpasswd.openshift | |
########################################################################### | |
### OpenShift Metrics and Logging Vars | |
########################################################################### | |
######################### | |
# Prometheus Metrics | |
######################### | |
# See more about it here: https://docs.openshift.com/container-platform/3.7/install_config/cluster_metrics.html#openshift-prometheus-roles | |
openshift_hosted_prometheus_deploy=true | |
openshift_prometheus_namespace=openshift-metrics | |
openshift_prometheus_node_selector={"node-role.kubernetes.io/infra":"true"} | |
openshift_cluster_monitoring_operator_install=true | |
######################## | |
# Cluster Metrics | |
######################## | |
# See more about it here: https://docs.openshift.com/container-platform/3.11/install_config/cluster_metrics.html | |
openshift_metrics_install_metrics=True | |
openshift_metrics_storage_kind=nfs | |
openshift_metrics_storage_access_modes=['ReadWriteOnce'] | |
openshift_metrics_storage_nfs_directory=/srv/nfs | |
openshift_metrics_storage_nfs_options='*(rw,root_squash)' | |
openshift_metrics_storage_volume_name=metrics | |
openshift_metrics_storage_volume_size=10Gi | |
openshift_metrics_storage_labels={'storage': 'metrics'} | |
openshift_metrics_cassandra_pvc_storage_class_name='' | |
openshift_metrics_hawkular_nodeselector={"node-role.kubernetes.io/infra": "true"} | |
openshift_metrics_cassandra_nodeselector={"node-role.kubernetes.io/infra": "true"} | |
openshift_metrics_heapster_nodeselector={"node-role.kubernetes.io/infra": "true"} | |
# Store Metrics for 2 days | |
openshift_metrics_duration=2 | |
# Quotas and limits for Prometheus components: | |
# See more variables about it here: https://gist.github.com/mjudeikis/146dfea9663639ac29117c5c8b1cb035 | |
# See other example of it here: https://github.com/remore/openshift-ha-cluster/blob/master/hosts.preserved | |
# Undertanding it better here: https://github.com/openshift/origin/tree/master/examples/prometheus | |
openshift_prometheus_memory_requests=2Gi | |
openshift_prometheus_cpu_requests=750m | |
openshift_prometheus_memory_limit=2Gi | |
openshift_prometheus_cpu_limit=750m | |
openshift_prometheus_alertmanager_memory_requests=300Mi | |
openshift_prometheus_alertmanager_cpu_requests=200m | |
openshift_prometheus_alertmanager_memory_limit=300Mi | |
openshift_prometheus_alertmanager_cpu_limit=200m | |
openshift_prometheus_alertbuffer_memory_requests=300Mi | |
openshift_prometheus_alertbuffer_cpu_requests=200m | |
openshift_prometheus_alertbuffer_memory_limit=300Mi | |
openshift_prometheus_alertbuffer_cpu_limit=200m | |
# Grafana | |
# See more about it here: https://github.com/openshift/origin/tree/master/examples/grafana | |
openshift_grafana_node_selector={"node-role.kubernetes.io/infra":"true"} | |
openshift_grafana_storage_type=pvc | |
openshift_grafana_pvc_size=2Gi | |
openshift_grafana_node_exporter=true | |
######################## | |
# Cluster Logging using NFS | |
######################## | |
# NFS is not the best approach for the logs and metrics. | |
# See more about types here: https://docs.openshift.com/container-platform/3.9/install_config/persistent_storage/index.html | |
# See more about aggreagtion logs here: https://docs.openshift.com/container-platform/3.11/install_config/aggregate_logging.html | |
openshift_logging_install_logging=True | |
openshift_logging_install_eventrouter=True | |
openshift_logging_storage_kind=nfs | |
openshift_logging_storage_access_modes=['ReadWriteOnce'] | |
openshift_logging_storage_nfs_directory=/srv/nfs | |
openshift_logging_storage_nfs_options='*(rw,root_squash)' | |
openshift_logging_storage_volume_name=logging | |
openshift_logging_storage_volume_size=10Gi | |
openshift_logging_storage_labels={'storage': 'logging'} | |
openshift_logging_es_pvc_storage_class_name='' | |
openshift_logging_es_memory_limit=8Gi | |
openshift_logging_es_cluster_size=1 | |
openshift_logging_curator_default_days=2 | |
openshift_logging_kibana_nodeselector={"node-role.kubernetes.io/infra": "true"} | |
openshift_logging_curator_nodeselector={"node-role.kubernetes.io/infra": "true"} | |
openshift_logging_es_nodeselector={"node-role.kubernetes.io/infra": "true"} | |
openshift_logging_eventrouter_nodeselector={"node-role.kubernetes.io/infra": "true"} | |
########################################################################### | |
### OpenShift Router and Registry Vars | |
########################################################################### | |
# See more about this configuration here: https://github.com/openshift/openshift-ansible/tree/master/roles/openshift_hosted | |
openshift_hosted_router_replicas=2 | |
openshift_hosted_registry_replicas=1 | |
openshift_hosted_registry_pullthrough=true | |
openshift_hosted_registry_acceptschema2=true | |
openshift_hosted_registry_enforcequota=true | |
openshift_hosted_registry_storage_kind=nfs | |
openshift_hosted_registry_storage_access_modes=['ReadWriteMany'] | |
openshift_hosted_registry_storage_nfs_directory=/srv/nfs | |
openshift_hosted_registry_storage_nfs_options='*(rw,root_squash)' | |
openshift_hosted_registry_storage_volume_name=registry | |
openshift_hosted_registry_storage_volume_size=20Gi | |
########################################################################### | |
### OpenShift Service Catalog Vars | |
########################################################################### | |
# See more about this feature here: https://docs.openshift.com/container-platform/3.11/architecture/service_catalog/index.html | |
# See more about this variables [here](https://docs.openshift.com/container-platform/3.10/install/configuring_inventory_file.html#configuring-cluster-variables | |
openshift_enable_service_catalog=true | |
template_service_broker_install=true | |
openshift_template_service_broker_namespaces=['openshift'] | |
ansible_service_broker_install=true | |
ansible_service_broker_local_registry_whitelist=['.*-apb$'] | |
What OS are you standing this cluster up on/what repo are your hosts referencing such that v3.11.16 is available?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
thanks for sharing