Skip to content

vBlog.nl

All about technology

Menu
  • Home
  • VMware Cloud Director
  • vSphere
  • Automation
    • PowerCLI
    • PowerShell
    • Terraform
  • NSX
  • Horizon DaaS
  • About Us
Menu

Setting up VMware Tanzu Community Edition on MacOS

Posted on October 22, 2021

In my previous post about the announcements made at VMworld 2021 I talked about the VMware Tanzu Community edition. Today I will show you how to set it up on MacOS

First of all I am using a Mac running MacOS 11.6 and its running on an Intel Mac (I know I also want the new M1 pro/max one).

So lets get started with Setting up VMware Tanzu Community Edition on MacOS shall we?

Table of Contents

    • Before you begin
    • Installing Tanzu Community Edition
  • Getting started with TCE
    • Deploy an app
    • Cleaning up
    • Wrap up

Before you begin

So lets first get the prerequisite in place. I need Homebrew, Docker and kubectl installed on my Mac.

I need to open terminal (or iTerm in my case) and run the following command:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

Once done you should see something like this:

Homebrew install

Now that I have Homebrew running I will install docker. Instructions for installing Docker can be found here.

Docker desktop deploy

You might want to check and see the resources assigned to run Docker, this way you will not consume all resources available to you. To change the resource settings open the Docker desktop and go to Settings –> Resources

Next to checking the resources I also checked to see if Docker is running correctly:

docker --version


This command should return something like this:

I have seen some issues out there where people did not get a proper version info. To fix this they had to open the Docker Desktop app and accept the basic setup steps. Maybe I am not running into an issue is that I already openend the Desktop app to set the resources.

And last but not least I will install kubectl:

brew install kubectl 


I can now see if kubectl was installed correctly by running the below command:

kubectl version


This should show something like this:

Installing Tanzu Community Edition

So now that I have all the prerequisites in place I will install Tanzu Community Edition (TCE).

As I installed Homebrew this part is just as simple as installing kubectl. Simply run the following commands.

brew tap vmware-tanzu/tanzu
brew install tanzu-community-edition


Once I finish the setup I am prompted to initialise the required plugins for TCE as you can see in the screenshot below.

So after running the above command I can get started with TCE and deploy my first cluster.

Getting started with TCE

So now that I have TCE running, I will setup a standalone cluster.

Again in terminal (or Iterm2) I run the following command to get the cluster going:

tanzu standalone-cluster create --ui


When I run this command the UI will open up in your browser to complete the setup.

First I select deploy on my local workstation but you could also deploy to vSphere, AWS and Azure.

starting your first cluster

Now all you need to do is provide a cluster name and use the NNF* solution to complete the wizard.

*Next next finish

Now this setup will take some time so get a coffee or thee, walk your dog, hug your wife or just watch and wait.

deploying the cluster

Once finished I can check to see if there is anything running:

First I do a context switch:

kubectl config use-context arjen-admin@arjen

*Note that where it says “arjen” you need to input your cluster name that you picked during the setup

Then I check to see what is running:

kubectl get nodes


I can see that the API node is running:

Deploy an app

So now that I have my cluster running let’s deploy an app to see if all is working as expected. I found this article from VMware that described deploying a demo app called kuard.

kubectl run --restart=Never --image=gcr.io/kuar-demo/kuard-amd64:blue kuard


Next I verify that the pod is running:

kubectl get pods


Which results in:

Now all I need to do is forward the pod container port 8080 to my local 8080 port on my Mac:

kubectl port-forward kuard 8080:8080


And now I can browse to http://localhost:8080 and should see something like this:

kuard app running

So now I have a fully working app on my Tanzu cluster running.

Cleaning up

Since I showed you how to setup TCE I will now show you how to clean up after your self (my wife would be proud)

First lets remove the kuard app:

kubectl delete pod kuard


Secondly, I will clean up the TCE standalone-cluster

tanzu standalone-cluster delete arjen

*Again, replace “arjen” with your cluster name

Once this is done I check to see if everything is cleaned up:

docker ps


Which should result in nothing running in Docker:

If you also want to remove TCE completely, you can run this command:

/usr/local/Cellar/tanzu-community-edition/v0.9.1/libexec/uninstall.sh


Wrap up

So there you have it Setting up VMware Tanzu Community Edition on MacOS. First I installed all the prerequisites, secondly I deployed TCS and thirdly I deployed a demo app.

Finally i cleaned up after my self.

I hope you enjoyed reading this blog and have fun deploying your own TCE environment.

Loading

Share on Social Media
x facebook linkedin reddit emailwhatsapptelegram

1 thought on “Setting up VMware Tanzu Community Edition on MacOS”

  1. mahendra says:
    February 23, 2022 at 3:38 am

    I tried to install it on my mac machine.

    I have all the prereqs
    I executed the following command on my command prompt:
    tanzu standalone-cluster create –ui

    and later I tried:
    tanzu management-cluster create –ui

    but I got this error consistently at setting up the control plane:

    Error: unable to set up management cluster: unable to create bootstrap cluster: failed to create kind cluster tkg-kind-c8apjqisahsoattvscpg: failed to init node with kubeadm: command “docker exec –privileged tkg-kind-c8apjqisahsoattvscpg-control-plane kubeadm init –skip-phases=preflight –config=/kind/kubeadm.conf –skip-token-print –v=6” failed with error: exit status 1

    Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Recent articles

  • Workspace ONE Access services monitoring July 11, 2023
  • vCloud Director API – Couldn’t connect to cloud server with the provided session id May 24, 2023
  • Horizon DaaS – Maximum sessions exceeded May 9, 2023
  • VMware Cloud on AWS with FSx for NetApp ONTAP December 28, 2022
  • Workspace ONE Access – Change certificate December 22, 2022
  • UI themes for VMware Cloud Director 10.4.1 and later December 16, 2022
  • VMware Tanzu Kubernetes Grid December 15, 2022
  • Workspace One Access – Not logged in to server FQDN. Please invoke Save before Sync December 12, 2022
  • NSX Edge configuration has failed. 1G hugepage support required. December 7, 2022
  • Horizon DaaS – Unable to connect to Desktop November 24, 2022

Tags

Automation bootstrapping Container Service Extension Credential Manager Desktone.log ESXi EUC EXi GPU Horizon DaaS Instant-Clone Logging NSX nsx-t PowerCLI PowerShell Putty Raspberry PI SSL Tanzu Terraform update vcd-cli vCenter vCloud vCloud Availability vCloud Director VDI vGPU VMware VMworld vSAN vSphere vVols workspace one Zerto

VMware Cloud Provider Blog

  • MongoDB Solution on VMware – Whitepaper Released!
    by Amith Vijayanand on November 28, 2023 at 4:46 pm

    VMware Cloud Director extension for VMware Data Solutions helps cloud service providers implement data solution services on their VMware multi-tenant platform. This extension enables service providers to build upon the underlying VMware Cloud Director infrastructure and policies by offering self-managed data services. Service providers can now supply additional data services at scale on top of … Continued The post MongoDB Solution on VMware – Whitepaper Released! appeared first on VMware Cloud Provider Blog.

  • Navigating the AI Maze: Beyond Regulation to Responsible Innovation
    by Guy Bartram on November 27, 2023 at 12:35 pm

    The dynamic and often unpredictable nature of Artificial Intelligence (AI) development has raised significant concerns about its governance. While regulation is key in managing these risks, standalone solutions like the new legislation AI Act in the EU and AI Bill of Rights in the USA is not enough, this is a global concern. The introduction … Continued The post Navigating the AI Maze: Beyond Regulation to Responsible Innovation appeared first on VMware Cloud Provider Blog.

  • VMware Cloud Director Availability 4.7 is now GA
    by Nikolay Patrikov on November 23, 2023 at 2:58 pm

    We are excited to announce that VMware Cloud Director Availability 4.7 is now Generally Available! The new version includes an important change in how the product handles the placement of a replicated workload at the destination cloud, several new additions that add flexibility to the replication storage settings, and more. New Replication Placement Mechanism    … Continued The post VMware Cloud Director Availability 4.7 is now GA appeared first on VMware Cloud Provider Blog.

  • How to customize IP Spaces’ IP allocation with Terraform
    by Nikodim Nikodimov on November 22, 2023 at 9:27 am

    Since its introduction in VMware Cloud Director (VCD) 10.4.1, IP Spaces has matured into a robust, feature-rich, structured approach for allocating IP addresses across VCD organizations. IP Spaces not only provides IP address management but also streamlines and automates a lot of the provider configuration work to supply their tenants with north-south communication paths. During … Continued The post How to customize IP Spaces’ IP allocation with Terraform appeared first on VMware Cloud Provider Blog.

  • Offer the Cloud Verified badge to your hosted partners and drive more platform consumption
    by Guy Bartram on November 17, 2023 at 11:17 am

    Are you a VMware Cloud Verified Services Provider whose customers are other Cloud Services Providers running in your data centers, or data centers you manage with your own hardware deployment and management stack? If you are then we have an opportunity for you…read on…. VMware Cloud Verified is a certified and validated designation that VMware … Continued The post Offer the Cloud Verified badge to your hosted partners and drive more platform consumption appeared first on VMware Cloud Provider Blog.

©2023 vBlog.nl | Design: Newspaperly WordPress Theme