Just found an awesome looking tool: icepanel that can be used to quickly create and visualize our Kubernetes microservice applications. It’s also very easy to use, you just need to install a VSCODE plugin.

Search for the plugin IcePanel in VSCODE and install it. Create a new empty workspace and in the bottom left corner you will see an Open IcePanel button, clicking on it will prompt us if we want to install the icepanel.yaml file. Allow by default and you will be able to enter the IcePanel page.

The operating page of IcePanel is very simple.

Currently IcePanel has several services pre-configured for us to use, such as the common ConfigMap, Deployment, Service and other resource objects.

Next, we use Kubernetes and IcePanel to deploy Wordpress and MySQL applications.

Here we use PVs to persist data, Service objects to expose services, and Secret objects to store password information.

  1. Creating Data Volumes

We need to create two data volumes to store the persistent data required by MySQL and Wordpress.

  1. Create MySQL

Then create a Deployment controller and Service object for Mysql and associate them by tags.

Click the Edit button on the Service to display its advanced properties. Then add a new port for 3306 to allow the Service to expose it.

We should now see a new connector appear on the Service, which is the port exposed above.

  1. Persisting MySQL Data

Now create a PVC object to associate with MySQL, so that you can use the PV object created earlier to persist the data.

  1. Configuring MySQL Passwords

Next, create a Kubernetes Secret object and edit it to add a password data field.

Once the password is created, we can connect the Secret object to MySQL’s ROOT_PASSWORD environment variable.

  1. Creating Wordpress

The next step is to create the Wordpress application, which also requires the creation of Deployment and Service objects.

Configure the Service to LoadBalancer via the property editor, but of course if it is not a cloud environment, we can use a Serivce of type NodePort.

  1. Persisting Wordpress data

As with MySQL, create a PVC object to persist Wordpress data.

  1. Associate MySQL and Wordpress

Finally, connect the MySQL database service and Secret to the Wordpress Deployment. At this point, we are done creating the Kubernetes Wordpress and MySQL applications.

  1. Deployment

In our current workspace, we already have the corresponding resource manifest file underneath our visualization, so we can deploy it directly to the Kubernetes cluster using the kubectl tool.