Learning path for developers
Following a curated learning path to deploy highly available containerized apps in Kubernetes clusters and use the powerful tools of IBM Cloud Kubernetes Service to automate, isolate, secure, manage, and monitor your app workloads across zones or regions.
Access the cluster
Begin working with your cluster by setting up the CLI and accessing the cluster.
- CLI setup: Set up the CLIs that are necessary to create and work with clusters. As you work with your cluster, refer to the command reference and keep track of CLI version updates with the CLI change log.
- User permissions: Ensure that your cluster administrator gives you the proper IBM Cloud IAM role to access the cluster.
- Cluster access: Access your cluster through the public or private cloud service endpoint.
Need help? Check out Troubleshooting clusters and masters and Troubleshooting worker nodes.
Plan your deployment
Before you deploy an app, decide how you want to set up your app so that your app can be accessed properly and be integrated with other services.
- Kubernetes-native: Plan your strategy for developing a Kubernetes-native app.
- Highly available: Plan your strategy for a highly available deployment.
Looking for serverless? Try Code Engine.
Develop your app
Configure your app in a YAML file that declares the configuration of the Kubernetes object, and plan your app versioning strategy.
- Develop your app:
- Review the basics of Kubernetes-native app deployments.
- Build app containers from images in public or private image registries.
- Specify your app requirements in a YAML file, which declares the configuration of the Kubernetes object.
- Version your app:
- To plan customized configurations for more than one environment, such as development, testing, and production environments, use the Kustomize tool to manage your configuration YAML file.
- If you want to run your app in multiple clusters, public and private environments, or even multiple cloud providers, package your application to help automate deployments.
Need help? Check out Troubleshooting apps and integrations.
Deploy your app
Deploy your app to the cluster by running your app configuration file.
- Deploying apps with the Kubernetes dashboard.
- Deploying apps with the CLI.
- Deploying apps to specific worker nodes by using labels.
- Deploying an app on a GPU machine.
Need help? Check out Troubleshooting apps and integrations.
Test, log, and monitor
While you conduct performance testing on your app, set up logging and monitoring to help you troubleshoot issues, gain visibility into your workloads, and improve the health and performance of your apps.
In a test environment, deliberately create various non-ideal scenarios, such as deleting all worker nodes in a zone to replicate a zonal failure. Review the logs and metrics to check how your app recovers.
- Test access: Test access to your app by creating a public or private NodePort on your worker nodes.
- Monitoring:
- Open a Kubernetes dashboard on your local system to view information about your app resources.
- Choose a monitoring solution, such as IBM Cloud® Monitoring, to gain operational visibility into the performance and health of your apps.
- Logging: Choose a logging solution, such as IBM® Log Analysis, to monitor container logs.
Need help? Check out Troubleshooting logging and monitoring.
Update your app
Perform rolling updates and rollbacks of apps without downtime for your users.
- Update strategy: Plan your strategy for keeping your app up-to-date.
- Set up updates:
- Add a rolling update to your deployment file
- Perform A/B, canary, and phased rollouts with the Istio managed add-on.
- Set up a continuous delivery pipeline for a cluster.
- Scaling: Enable horizontal pod autoscaling to automatically increase or decrease the number of instances of your apps based on CPU.
Secure your app
Use Kubernetes secrets to store confidential information, such as credentials or keys, and encrypt data in Kubernetes secrets to prevent unauthorized users from accessing sensitive app information.
- Secrets:
- Store personal or sensitive information in Kubernetes secrets that your app can access.
- Encrypt secrets by using a KMS provider.
- Verify that secrets are encrypted.
- Pod-to-pod traffic: Enable mTLS encryption for traffic between microservices within an Istio service mesh.
Expose your app
Publicly expose an app in your cluster to the internet or privately expose an app in your cluster to the private network only.
- Plan service discovery:
- Understand the basics of Kubernetes service discovery.
- Choose an app exposure service that fits your requirements for incoming traffic to the app.
- Expose your app:
-
Load balancers:
- Classic clusters:
- Create an NLB 1.0 or NLB 2.0.
- Register a DNS subdomain for the NLB.
- VPC clusters: Set up a VPC load balancer.
- Classic clusters:
-
Ingress: Configure Ingress for the public or private network.
-
Need help? Check out Troubleshooting Ingress and Troubleshooting load balancers.
Add app storage
- Requirements: Determine your requirements for a storage solution.
- Choose a solution: Using your storage requirements, choose a storage solution by comparing your options.
Need help? Check out the troubleshooting page for your persistent storage solution.
Add integrations
Enhance app capabilities by integrating various external services and catalog services in your cluster with your app.
- Review supported integrations:
- Add services to your cluster: Ask your cluster administrator to add the integration to your cluster.
- Access services from your app: Ensure that your app can access the service. For example, to access an IBM Cloud service instance from your app, you must make the service credentials that are stored in the Kubernetes secret available to your app.
Need help? Check out Troubleshooting apps and integrations. {: tip}f