-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat/oci: add initial steps to create network resources feat/oci: add DNS, LB and network feat/provider-oci: add full-stack creation oci create cluster successfully running Update installing-agnostic-oci.md Update installing-agnostic-oci.md feat/oci: documenting the cluster create vars fix/nsg: compute nodes were using CP NSG feat/destroy: add OCI destroy resources feat/os_mirror: add OS image mirror role feat/destroy: add OCI destroy resources doc: update image with os_mirror, destroy and opct oci patchs: Platform External and CCM manifests oci/ccm: adapting to inject CCM manifests into install flow oci/csi: adapting to inject CSI manifests on install time oci: review to install and validate CCM and CSI compute: creating generic compute var to allow customization creating release 4.13.0-rc.0 installing with ccm+csi remove commented lines chore: reuse items on var files
- Loading branch information
Showing
86 changed files
with
3,840 additions
and
7 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Steps to Integrate a new Provider into okd-installer | ||
|
||
> Placeholder |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Guides for Oracle Cloud Infrastructure | ||
|
||
> WIP | ||
> TODO: | ||
Create guides/docs for OCP/OKD on OCI: | ||
|
||
- Installing a cluster with agnostic installation quickly (Platform=None) | ||
- Installing a cluster with Cloud Controller Manager using External provider (Platform=External) | ||
- Installing a cluster with External Cloud provider integration: CCM and `Platform External` | ||
- Installing a cluster with agnostic installation with Assisted Installer as a installation provider | ||
|
||
Generic guides: | ||
|
||
- Integrate new provider to the Ansible Collection (UPI stacks) | ||
- Adding CCM to existing integrated external provider |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# OCI Image Registry - Use S3 compatibility URL for persistent storage | ||
|
||
> WIP | ||
Steps to use the OCI S3 Compatibility API to set the persistent storage for the OpenShift Image Registry with OCI Bucket service. | ||
|
||
Steps: | ||
|
||
- Create access Key | ||
- Create the secret used by image-registry | ||
- Edit the image registry object adding the s3 configuration | ||
- Test it |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
## Install a cluster on OCI with CCM | ||
|
||
## Requirements | ||
|
||
- Credentials | ||
- Client installed | ||
|
||
## OCP Cluster Setup on OCI | ||
|
||
### Generate the vars file | ||
|
||
```bash | ||
cat <<EOF > ~/.oci/env | ||
# Compartment that the cluster will be installed | ||
OCI_COMPARTMENT_ID="<CHANGE_ME:ocid1.compartment.oc1.UUID>" | ||
# Compartment that the DNS Zone is created (based domain) | ||
# Only RR will be added | ||
OCI_COMPARTMENT_ID_DNS="<CHANGE_ME:ocid1.compartment.oc1.UUID>" | ||
# Compartment that the OS Image will be created | ||
OCI_COMPARTMENT_ID_IMAGE="<CHANGE_ME:ocid1.compartment.oc1.UUID>" | ||
EOF | ||
source ~/.oci/env | ||
|
||
cat <<EOF > ~/.openshift/env | ||
export OCP_CUSTOM_RELEASE="docker.io/mtulio/ocp-release:latest" | ||
OCP_RELEASE_413="quay.io/mrbraga/ocp-release:4.13.0-rc.0-x86_64_platexternal-kcmo-mco-3cmo" | ||
EOF | ||
source ~/.openshift/env | ||
|
||
CLUSTER_NAME=oci-t13 | ||
VAR_FILE=./vars-oci-ha_${CLUSTER_NAME}.yaml | ||
|
||
cat <<EOF > ${VAR_FILE} | ||
provider: oci | ||
cluster_name: ${CLUSTER_NAME} | ||
config_cluster_region: us-sanjose-1 | ||
#TODO: create compartment validations | ||
#TODO: allow create compartment from a parent | ||
oci_compartment_id: ${OCI_COMPARTMENT_ID} | ||
oci_compartment_id_dns: ${OCI_COMPARTMENT_ID_DNS} | ||
oci_compartment_id_image: ${OCI_COMPARTMENT_ID_IMAGE} | ||
cluster_profile: ha | ||
destroy_bootstrap: no | ||
config_base_domain: splat-oci.devcluster.openshift.com | ||
config_ssh_key: "$(cat ~/.ssh/id_rsa.pub;cat ~/.ssh/openshift-dev.pub)" | ||
config_pull_secret_file: "${HOME}/.openshift/pull-secret-latest.json" | ||
config_cluster_version: 4.13.0-rc.0 | ||
version: 4.13.0-rc.0 | ||
config_installer_environment: | ||
OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE: "$OCP_RELEASE_413" | ||
# Define the OS Image mirror | ||
os_mirror: yes | ||
os_mirror_from: stream_artifacts | ||
os_mirror_stream: | ||
architecture: x86_64 | ||
artifact: openstack | ||
format: qcow2.gz | ||
os_mirror_to_provider: oci | ||
os_mirror_to_oci: | ||
compartment_id: ${OCI_COMPARTMENT_ID_IMAGE} | ||
bucket: rhcos-images | ||
image_type: QCOW2 | ||
## Apply patches to installer manifests (WIP) | ||
# TODO: we must keep the OCI CCM manifests patch more generic | ||
config_patches: | ||
- rm-capi-machines | ||
- mc-kubelet-providerid | ||
- deploy-oci-ccm | ||
- deploy-oci-csi | ||
- yaml_patch | ||
cfg_patch_yaml_patch_specs: | ||
## patch infra object to create External provider | ||
- manifest: /manifests/cluster-infrastructure-02-config.yml | ||
patch: '{"spec":{"platformSpec":{"type":"External","external":{"platformName":"oci"}}},"status":{"platform":"External","platformStatus":{"type":"External","external":{}}}}' | ||
cfg_patch_kubelet_providerid_script: | | ||
PROVIDERID=\$(curl -H "Authorization: Bearer Oracle" -sL http://169.254.169.254/opc/v2/instance/ | jq -r .id); | ||
EOF | ||
``` | ||
|
||
### Install the cluster | ||
|
||
```bash | ||
ansible-playbook mtulio.okd_installer.create_all \ | ||
-e certs_max_retries=20 \ | ||
-e cert_wait_interval_sec=60 \ | ||
-e @$VAR_FILE | ||
``` | ||
|
||
## Destroy | ||
|
||
```bash | ||
ansible-playbook mtulio.okd_installer.destroy_cluster -e @$VAR_FILE | ||
``` |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,90 @@ | ||
# Installing in OCI with build-in examples | ||
|
||
## Export variables | ||
|
||
```bash | ||
export OKD_CONFIG_BASE_DOMAIN="<CHANGE_ME:base_domain_value>" | ||
export OCI_COMPARTMENT_ID="<CHANGE_ME:compartment_id>" | ||
export OCI_COMPARTMENT_ID_DNS="<CHANGE_ME:compartment_id>" | ||
export OCI_COMPARTMENT_ID_IMAGE="<CHANGE_ME:compartment_id>" | ||
export OS_MIRROR_IMAGE_BUCKET_NAME="rhcos-images" | ||
``` | ||
|
||
### Default vars | ||
|
||
|
||
## Installing | ||
|
||
|
||
### Installing a cluster on OCI with Platform Agnostic/None | ||
|
||
> TODO | ||
```bash | ||
ansible-playbook examples/create-cluster.yaml \ | ||
-e cluster_name=name \ | ||
-e @./examples/vars/common.yaml \ | ||
-e @./examples/vars/oci/common.yaml \ | ||
-e @./examples/vars/oci/ha-platform-none.yaml | ||
``` | ||
|
||
### Installing a cluster on OCI with Platform Agnostic/None with CSI Driver | ||
|
||
```bash | ||
ansible-playbook examples/create-cluster.yaml \ | ||
-e cluster_name=name \ | ||
-e @./examples/vars/common.yaml \ | ||
-e @./examples/vars/oci/common.yaml \ | ||
-e @./examples/vars/oci/ha-platform-none-csi.yaml | ||
``` | ||
|
||
### Installing a cluster on OCI with Platform External | ||
|
||
```bash | ||
ansible-playbook examples/create-cluster.yaml \ | ||
-e cluster_name=name \ | ||
-e @./examples/vars/common.yaml \ | ||
-e @./examples/vars/oci/common.yaml \ | ||
-e @./examples/vars/oci/ha-platform-external.yaml | ||
``` | ||
|
||
### Installing a cluster on OCI with Platform External with CCM | ||
|
||
```bash | ||
ansible-playbook examples/create-cluster.yaml \ | ||
-e cluster_name=name \ | ||
-e @./examples/vars/common.yaml \ | ||
-e @./examples/vars/oci/common.yaml \ | ||
-e @./examples/vars/oci/ha-platform-external-ccm.yaml | ||
``` | ||
|
||
### Installing a cluster on OCI with Platform External with CCM and CSI Driver | ||
|
||
```bash | ||
ansible-playbook examples/create-cluster.yaml \ | ||
-e cluster_name=name \ | ||
-e @./examples/vars/common.yaml \ | ||
-e @./examples/vars/oci/common.yaml \ | ||
-e @./examples/vars/oci/ha-platform-external-ccm-csi.yaml | ||
``` | ||
|
||
### Installing a cluster on OCI with Platform External with CSI Driver | ||
|
||
> TODO: OCI CSI Driver can be installed in Platform None with manual changes | ||
<!-- ### Installing a cluster on OCI with Platform None and Assisted Installer as Config Provider | ||
```bash | ||
ansible-playbook examples/create-cluster.yaml \ | ||
-e cluster_name=name \ | ||
-e @./examples/vars/common.yaml \ | ||
-e @./examples/vars/oci/common.yaml \ | ||
-e @./examples/vars/oci/AI-ha-platform-none.yaml | ||
``` --> | ||
|
||
### Destroy a cluster | ||
|
||
```bash | ||
ansible-playbook mtulio.okd_installer.destroy_cluster \ | ||
-e cluster_name=name | ||
``` |
Oops, something went wrong.