{"id":27951219,"url":"https://github.com/mirantis/trymosk-virtual","last_synced_at":"2025-05-07T16:16:49.554Z","repository":{"id":272941832,"uuid":"862245576","full_name":"Mirantis/trymosk-virtual","owner":"Mirantis","description":null,"archived":false,"fork":false,"pushed_at":"2025-04-28T09:38:59.000Z","size":152,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-05-07T16:16:39.739Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Mirantis.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-09-24T09:26:23.000Z","updated_at":"2025-04-28T09:39:03.000Z","dependencies_parsed_at":"2025-01-17T15:48:11.181Z","dependency_job_id":"7a61178c-a142-467b-b675-d7e19a17c080","html_url":"https://github.com/Mirantis/trymosk-virtual","commit_stats":null,"previous_names":["mirantis/trymosk-virtual"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mirantis%2Ftrymosk-virtual","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mirantis%2Ftrymosk-virtual/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mirantis%2Ftrymosk-virtual/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mirantis%2Ftrymosk-virtual/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Mirantis","download_url":"https://codeload.github.com/Mirantis/trymosk-virtual/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252912937,"owners_count":21824068,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-05-07T16:16:44.600Z","updated_at":"2025-05-07T16:16:49.542Z","avatar_url":"https://github.com/Mirantis.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TryMOSK for on-premise self-evaluation\n\nThis project is developed for demo purposes on\n[Mirantis Container Cloud (MCC)](https://docs.mirantis.com/container-cloud/latest/overview.html)\nand\n[Mirantis OpenStack for Kubernetes (MOSK)](https://docs.mirantis.com/mosk/latest/overview.html)\nproducts on top of the vSphere infrastructure.\n\n## Requirements\n\nThe project contains scripts for automated deployment of an MCC management cluster\nMOSK managed cluster. The workflow of scripts is as follows:\n\n- Create subfolders in the provided `VSPHERE_FOLDER` for VM placement.\n- Create the MCC seed VM with the bootstrap cluster and minimal set of components\n  that require the following resources: 8 CPUs, 16 GB of RAM, 30 GiB disk.\n- Create 3 VMs for a management cluster that requires the following resources:\n   - 8 CPUs\n   - 32 GB of RAM\n   - Single 150 GiB disk\n   - Attach to Life-Cycle Management (LCM) network\n- Create 6 VMs for a managed cluster containing 3 control plane and 3 worker nodes\n  that requires the following resources:\n  - 8 CPUs and 24 GB RAM for control plane nodes\n  - 8 CPUs and 16 GB RAM for worker nodes\n  - 2 disks: 80 GiB for root partition and 40 GiB for Ceph storage\n  - 2 networks: LCM and OpenStack\n- Manage MCC and MOSK cluster deployment.\n- Save deployment artifacts.\n- Provide access to the deployed environments.\n\n\u003e Note: You can change VM parameters using the related environment variables. For details, run:\n\u003e\n\u003e ```./deploy.sh help```\n\n### Network configuration\n\nDemo environment setup requires two dedicated networks assigned for the project deployment:\n\n- **LCM network**: used for MCC cluster setup (including machines provisioning)\n  and for access to the MCC services. From MCC standpoint, this network is used as\n  public network to download MCC artifacts, so it must have access to the Internet\n  or to the proxy (if used).\n\n- **Openstack network**: used to access virtual machines created on top of\n  deployed OpenStack cluster. This network must be routable in your infrastructure\n  so that you can access OpenStack VMs.\n\nYou must provide a subnet range and gateway for each of these networks, for example:\n\n```\nVSPHERE_NETWORK_LCM=\"/\u003cdatacenter\u003e/network/\u003clcm network name\u003e\"\nNETWORK_LCM_SUBNET=172.16.10.0/24\nNETWORK_LCM_GATEWAY=172.16.10.1\nNETWORK_LCM_RANGE=172.16.10.2-172.16.10.100\n\nVSPHERE_NETWORK_OPENSTACK=\"/\u003cdatacenter\u003e/network/\u003copenstack network name\u003e\"\nNETWORK_OPENSTACK_SUBNET=172.16.20.0/24\nNETWORK_OPENSTACK_GATEWAY=172.16.20.1\nNETWORK_OPENSTACK_RANGE=172.16.20.2-172.16.20.100\n```\n\n\u003e Note: vSphere networks must be configured with following network policies:\n\u003e\n\u003e - Promiscuous mode: Accept\n\u003e - MAC address changes: Accept\n\u003e - Forged transmits: Accept\n\n### vSphere access\n\nThe deployment script requires the vSphere user to access vSphere API.\nThe user manages full MCC installation onto your infrastructure\nand requires the following privileges:\n\n- Datastore\n- Distributed switch\n- Folder\n- Global\n- Host local operations\n- Network\n- Resource\n- Scheduled task\n- Sessions\n- Storage views\n- Tasks\n- Virtual machine\n\n## Prerequisites\n\nThe deloyment script requires following utils to be installed on the machine\nwhere the script will be executed:\n\n- `curl`\n- `jq`\n- `python3`\n- `ssh`, `scp`, `ssh-keygen`\n- `tar`\n- `virtualenv`\n- `govc` (installed automatically if not present)\n\n### Seed node\n\nThe seed or bootstrap node is an initial node in the MCC deployment that contains the\nbootstrap cluster and MCC configuration. It is mandatory to prepare this seed node\nfrom the Ubuntu 22.04 image. You can download the official Ubuntu 22.04 `vmdk` image\nfrom the following [page](https://cloud-images.ubuntu.com/releases/22.04/release/).\n\nYou can upload the image directly to the dedicated vSphere datastore and provide\nits path using the `VSPHERE_VMDK_IMAGE_DATASTORE_PATH` variable or you can download\nthe image locally and provide it using the `VSPHERE_VMDK_IMAGE_LOCAL_PATH` variable.\n\nNot recommended: as an alternative, you can use an existing VM template of Ubuntu 22.04\nwith the latest version of `cloud-init` installed. You can provide the VM template\nusing the `VSPHERE_VM_TEMPLATE` variable. Ensure to specify the full path to the template\nto uniquely identify it in your vSphere cluster.\n\n## Get started\n\n### Environment variables\n\nRun the following command to obtain detailed information about the script along with\navailable commands and parameters:\n\n```./deploy.sh help```\n\n#### Minimal mandatory parameters\n\n```\nVSPHERE_SERVER=\"\u003cfqdn or ip\u003e\"\nVSPHERE_USERNAME=\"\u003cusername\u003e\"\nVSPHERE_PASSWORD=\"\u003cpassword\u003e\"\nVSPHERE_DATACENTER=\"\u003cdatacenter\u003e\"\nVSPHERE_DATASTORE=\"/\u003cdatacenter\u003e/datastore/\u003cdatastore name\u003e\"\nVSPHERE_RESOURCE_POOL=\"/\u003cdatacenter\u003e/host/\u003cvsphere cluster name\u003e/Resources/\u003cresource pool name\u003e\"\nVSPHERE_VMDK_IMAGE_DATASTORE_PATH=\"\u003cfolder\u003e/ubuntu-22.04-server-cloudimg-amd64.vmdk\"\nVSPHERE_FOLDER=\"/\u003cdatacenter\u003e/vm/\u003cfolder name\u003e/mcc\"\nVSPHERE_SERVER_INSECURE=\"true\"\n\nVSPHERE_NETWORK_LCM=\"/\u003cdatacenter\u003e/network/\u003clcm network name\u003e\"\nNETWORK_LCM_SUBNET=172.16.10.0/24\nNETWORK_LCM_GATEWAY=172.16.10.1\nNETWORK_LCM_RANGE=172.16.10.2-172.16.10.100\n\nVSPHERE_NETWORK_OPENSTACK=\"/\u003cdatacenter\u003e/network/\u003copenstack network name\u003e\"\nNETWORK_OPENSTACK_SUBNET=172.16.20.0/24\nNETWORK_OPENSTACK_GATEWAY=172.16.20.1\nNETWORK_OPENSTACK_RANGE=172.16.20.2-172.16.20.100\n\nNTP_SERVERS=us.pool.ntp.org,pool.ntp.org\nNAMESERVERS=8.8.8.8,8.8.4.4\n```\n\n#### Variables for proxy settings\n\n```\nHTTP_PROXY=\"\u003chttp proxy url\u003e\"\nHTTPS_PROXY=\"\u003chttps proxy url\u003e\"\nNO_PROXY=\"\u003ccomma-separated list of no proxy hosts\u003e\" # should include vsphere fqdn and IP\nPROXY_CA_CERTIFICATE_PATH=\"\u003cpath\u003e/\u003cto\u003e/certificate.pem\" # in case of MITM proxy\n```\n\n### Deploy the MCC environment\n\nTo deploy the whole environment using a single command:\n\n```./deploy.sh all```\n\nThe deployment stages of the MCC environment are as follows:\n\n1. Set up the seed node\n1. Prepare the bootstrap cluster\n1. Create and provision management and managed cluster machines\n1. Deploy the MCC management cluster:\n   1. Set up the host operating system\n   1. Set up Kubernetes\n   1. Deploy MCC controllers\n1. Deploy the MCC managed cluster:\n   1. Set up the host operating system\n   1. Set up Kubernetes\n   1. Deploy Ceph\n   1. Deploy OpenStack\n\n## Cleanup\n\nThe deployment script can clean up the created vSphere objects used by\nthe deployed environment. During cleanup, the following items are removed:\n\n- All VMs in `seed`, `management`, and `managed` folders inside the provided\n  `VSPHERE_FOLDER`\n- All disks attached to VMs including the copy of the `vmdk` image for the seed node\n\nTo clean up the created vSphere objects:\n\n```./deploy.sh cleanup```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmirantis%2Ftrymosk-virtual","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmirantis%2Ftrymosk-virtual","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmirantis%2Ftrymosk-virtual/lists"}