Kubernetes Cluster Setup with Automated Scaling and Pay-per-Use Pricing

Kubernetes Cluster Setup with Automated Scaling and Pay-per-Use Pricing

Kubernetes (K8s) is a leading platform for deploying and managing fault-tolerant containerized applications. It’s used to build cloud-native, microservice architectures and helps companies migrate existing projects into containers for greater efficiency and resilience. A K8s cluster can manage complex container orchestration tasks, including deployment, service discovery, rolling upgrades, self-healing, and security management. Its effortless deployment and scalability make it a top choice for modern IT environments.

The Cloud Native Computing Foundation , which encourages cloud portability without vendor lock-in, supports the Kubernetes project. It is possible to deploy Kubernetes clusters on bare metal, public cloud, and private cloud environments.

However, setting up a Kubernetes cluster from scratch on your own servers is complex. It calls for a thorough comprehension of the cluster’s constituent parts, their interconnections, and the ability to monitor and troubleshoot. For a detailed guide, refer to the Kubernetes The Hard Way article.

Managed Kubernetes services simplify and automate many operations, but the challenge of right-sizing still remains. You need to be quite exact in estimating the number of worker nodes and the containers that operate on them in order to maximize efficiency. Otherwise, you risk paying for large, underutilized workers or using small VMs and relying on automatic horizontal scaling, which can add complexity.

AccuWeb.Cloud has addressed several challenges and provided essential features to simplify Kubernetes hosting  while optimizing resource consumption:

  • The complex cluster setup is fully automated and streamlined into a “one-click” process within an intuitive UI.
  • Instant vertical scaling based on load changes is fully automated by the platform.
  • Fast automatic or manual horizontal scaling of Kubernetes worker nodes is facilitated with integrated autodiscovery.
  • The pay-per-use pricing model is available for Kubernetes hosting, eliminating the need to overpay for reserved but unused resources.
  • AccuWeb.Cloud Shared Storage is integrated with Dynamic Volume Provisioner, automatically placing physical volumes used by applications on the storage drive. These volumes can be accessed via SFTP/NFS or the integrated file manager.
  • No public IPs are required by default. A shared load balancer, which functions as a proxy server, handles all incoming requests and is included by default.
  • Clusters can be provisioned across multiple regions, clouds, and on-premises environments with consistent configurations and no vendor lock-in.

Jelastix Kubernetes Cluster Topology

AccuWeb.Cloud PaaS provides a Kubernetes cluster with the following pre-installed components:

  • Containers: A runtime controller.
  • Weave CNI plugin: Supports overlay networking.
  • Traefik ingress controller: Handles HTTP/HTTPS requests to services.
  • HELM package manager: Automatically installs pre-packaged solutions from repositories.
  • CoreDNS: Resolves internal names.
  • Dynamic provisioner of persistent volumes: Manages storage provisioning.
  • Dedicated NFS storage: Offers persistent storage.
  • Metrics Server: Collects cluster statistics.
  • AccuWeb.Cloud SSL: Secures the ingress network.
  • Web UI Dashboard: Provides a user interface for cluster management.

Kubernetes Cluster Installation

Step 1. To begin, log in to the dashboard, locate the Kubernetes Cluster in the Marketplace, and click Install. This clustering solution is only accessible to billing clients; learn more about trial limits.

Kubernetes Cluster Installation

Step 2. Next, select the required cluster topology. Two options are available:

  • Development: lightweight version for testing and development purposes.
  • Production: Cluster with pre-configured high availability for running applications in production.

Select Topology

Step 3. Attach dedicated NFS Storage with dynamic volume provisioning.

Every node has a read-write filesystem with read-write permissions by default. However, for access from other containers or persistence after redeployments, data should be placed on a dedicated volume.

You can use a custom dynamic volume provisioner by specifying the required settings in your deployment YAML files.

Alternatively, you can use the pre-configured volume manager and NFS Storage built into the AccuWeb.Cloud Kubernetes cluster. As a result, physical volumes will be provisioned dynamically on demand and connected to the containers. The Storage Node can be accessed and managed using the file manager via the dashboard, SFTP, or any NFS client.

NFS Storage

Step 4. If needed, you can install additional software to monitor and troubleshoot your Kubernetes (K8s) cluster, and enable API access using the provided checkboxes:

  • Install Prometheus & Grafana: Monitor the health of your K8s cluster and applications. This requires an additional 5GB of disk space for persistent volumes and about 500 MB of RAM.
  • Install Jaeger Tracing Tools: Ensure effective troubleshooting for distributed services.
  • Enable Remote API Access: Manage your K8s cluster via API.

Enable Remote API Access

If you choose not to install these now, you can add them later using the specific Cluster Configuration add-on.

Step 5. To showcase all the package features and details, we will install the Open Liberty application server runtime in a Production Kubernetes cluster topology with built-in NFS storage.

Click the Install button and wait a few minutes. Once the installation is complete, the cluster topology will look as follows:

Open Liberty Application

Step 6. You can access the Kubernetes administration dashboard and the Open Liberty application server welcome page from the successful installation window.

Use the Access Token and follow the Kubernetes dashboard link to manage your Kubernetes cluster.

Access Token

Token

Kubernetes Dashboard

Access the default Kubernetes page by pressing the Open in Browser button.

Open In Browser

Result in Browser

AccuWeb.Cloud Kubernetes Distribution Add-Ons

AccuWeb.Cloud K8s package includes specific add-ons available at the master node, designed to:

Add-Ons

which are designed to:

Install SSL Certificate Manager:

First, attach a public IP to one of the worker nodes.

Create an A record for your external domain (e.g., SSLservice.accu.website) using the public IP.

Enter this domain name in the Certificate Manager user interface and press Apply.

Install SSL Certificate Manager

This tool not only manages SSL certificates but also deploys a separate ingress controller to balance workloads among applications tied to the workers’ public IPs. Consequently, all internal resources become accessible via worker nodes’ hostnames like node${nodeId}-${envName}.${platformDomain}, except for the worker node using the public IP bound to the external domain (e.g., myservice.jele.website) through the Certificate Manager.

  • Enable/Disable GitLab Server Integration within AccuWeb.Cloud PaaS.
  • Automatically Upgrade the Kubernetes Cluster.
  • Enable Remote API Access (if it wasn’t enabled during installation).

Remote API

  • Install and Configure Monitoring Tools:
    • Prometheus and Grafana: If not enabled during installation, these tools can be set up to monitor your cluster.

After installation, you’ll receive an email and a pop-up with access credentials.

Credentials Notification

  • Install Tracing Tool Jaeger:

Similarly, after installation, an email and a pop-up with access credentials will be sent.

Access Credentials

Remote API Access to Kubernetes Cluster

To remotely access and manage your created Kubernetes cluster using the API, select the Enable Remote API Access checkbox.

Remote API Access

Use the provided Remote API Endpoint link and access Token to connect to the Kubernetes API server (Balancer or Master node).

Remote API Endpoint

The best way to interact with the API server is through the Kubernetes command line tool, kubectl:

  • Install the kubectl utility on your local computer by following the official guide. For this example, we’ve used the installation for Ubuntu Linux.
  • Set up local configuration for kubectl by opening a terminal on your local computer and running the following commands:

$ kubectl config set-cluster mycluster --server={API_URL}
$ kubectl config set-context mycluster --cluster=mycluster
$ kubectl config set-credentials user --token={TOKEN}
$ kubectl config set-context mycluster --user=user
$ kubectl config use-context mycluster
Where:
{API_URL} - Remote API Endpoint link
{TOKEN} - Access Token

Now, you can manage your Kubernetes cluster from your local computer by following the official tutorial.
For instance, to view all available nodes in your cluster, open a local terminal and run the following kubectl command:


kubectl get nodes

Manage K8s

To disable or enable the API service after installation, use the Master node Configuration Add-On.

Remote API

Enable API

Cluster Upgrade

To keep your Kubernetes cluster software up-to-date, use the Cluster Upgrade Add-On. Simply click the Start Cluster Upgrade button.

The add-on will check if a new version is available, and if so, it will install the update. During the upgrade, all nodes, including masters and workers, will be redeployed to the new version one by one, while preserving all existing data and settings.

Note that the upgrade process is sequential, so if your current version is significantly outdated, you may need to run the upgrade multiple times to reach the latest version. The upgrade option becomes available only when a new version is globally released by the AccuWeb.Cloud team.

Start Cluster Upgrade

To avoid application downtime during the redeployment, consider using multiple replicas for your services.

Statistics and Pay-per-Use Billing

AccuWeb.Cloud provides automatic vertical scaling for each worker and master node in a Kubernetes cluster, allocating resources on demand based on real-time load. This means you don’t need to constantly monitor changes, as the system does it for you.

Additionally, you can easily check the current load across a group of nodes or each node individually by pressing the Statistics button next to the desired layer or node.

Statistics

This highly automated scaling and full containerization enable AccuWeb.Cloud PaaS offers a billing model that is relatively new to cloud computing. This “pay-per-use” or “pay-as-you-use” approach is considered the most cost-effective, as you only pay for the resources you actually use. This model eliminates the need to over allocate resources, solving the “right-sizing” problem inherent in the older “pay-per-limits” or “pay-as-you-go” models.

The billing process is transparent and can be tracked through the dashboard under Balance > Billing History. The price is based on the number of consumed resource units, called cloudlets (128MiB + 400MHz). This granularity provides flexibility in billing and clarity in cloud expenditures.

Billing History

AccuWeb.Cloud PaaS supports automatic vertical scaling of Kubernetes cluster nodes, automatic horizontal scaling with auto-discovery of newly added workers, management via an intuitive UI, and implementation of CI/CD pipelines with Cloud Scripting and open APIs.

For private setups, the platform can provision clusters across multiple clouds and on-premises environments without vendor lock-in, ensuring full interoperability across clouds.

This allows your team to focus on developing applications and services rather than managing infrastructure and API differences of each Kubernetes service implementation.

Try it out with one of the public AccuWeb.Cloud PaaS service providers and share your feedback for further improvements!

Save $100 in the next
5:00 minutes?

Register Here