diff --git a/content/_index.md b/content/_index.md index 8e8229be8..5c2ab6ff0 100644 --- a/content/_index.md +++ b/content/_index.md @@ -12,6 +12,7 @@ Welcome to dev environment for your Academy [LearningPaths](/academy/learning-paths/) +[Challenges](/academy/challenges/) {{% /blocks/lead %}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/_index.md b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/_index.md new file mode 100644 index 000000000..69cc09056 --- /dev/null +++ b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/_index.md @@ -0,0 +1,9 @@ +--- +title: "CNCF Autoscaling Challenge" +description: "Learn event-driven autoscaling in Kubernetes. Work with scaled objects in KEDA, monitoring with Prometheus, Open Telemetry & CloudEvents and advanced KEDA configurations." +themeColor: "#3C494F" +banner: "11111111-1111-1111-1111-111111111111/images/keda-icon.svg" +courses: 1 +weight: 1 +type: learning-paths +--- diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/_index.md b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/_index.md new file mode 100644 index 000000000..56d59fc27 --- /dev/null +++ b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/_index.md @@ -0,0 +1,20 @@ +--- +docType: "Course" +title: 'Autoscaling with KEDA' +description: "Design an event-driven autoscaling architecture using KEDA." +courseTitle: "Autoscaling with KEDA" +themeColor: "#00B39F" +lectures: 3 +weight: 1 +--- + +## Objective +A challenge to help you set up KEDA and start using it to build real-life applications with event-driven autoscaling in Kubernetes. Learn how to configure KEDA as an autoscaling solution, enabling your workloads to scale based on external metrics such as message queue length, database size, or custom application metrics. + +## Prerequisites + +**Access to Meshery**: +You will need access to a Meshery server, either Self-Hosted or the [Meshery Playground](https://playground.meshery.io/). + +**Learn KEDA Concepts**: Study [KEDA's key concepts](https://trainingportal.linuxfoundation.org/learn/course/scaling-cloud-native-applications-with-keda-lfel1014/course-introduction/course-information?page=1), including ScaledObjects, ScaledJobs, and various scalers. The Linux Foundation course provides a comprehensive introduction to these concepts, which are essential for completing the challenge successfully. +**Learn to use Meshery**: Go through the Mastering Meshery Learning Path to gain proficiency in using Meshery for designing, deploying, and managing your KEDA-based architecture. diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/content/description.md b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/content/description.md new file mode 100644 index 000000000..086e9f330 --- /dev/null +++ b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/content/description.md @@ -0,0 +1,115 @@ +--- +docType: "Chapter" +id: "What is this Challenge About" +description: "This competition will challenge you to design an architecture diagram that demonstrates how KEDA can be used to automatically scale applications in a Kubernetes environment based on event-driven metrics. You'll learn how to configure KEDA scalers, how to integrate various event sources, and how to visualize the autoscaling process in a complex microservices architecture. This challenge will deepen your understanding of event-driven autoscaling in cloud-native environments and showcase how KEDA enhances Kubernetes' native scaling capabilities" +chapterTitle: "What is this Challenge About" +title: "What is this Challenge About" +weight: 2 +--- + +### **Overview** + +In this challenge, you will design and implement an event-driven autoscaling solution using [Kubernetes Event-Driven Autoscaling (KEDA)](https://keda.sh/). Your task is to create a deployable design that demonstrates KEDA's capabilities in a microservices architecture. This challenge will test your skills in creating a system that can efficiently respond to fluctuating workloads driven by real-world events. + +### **Setting the Stage with KEDA** + +KEDA (Kubernetes Event-Driven Autoscaling) is an open-source, lightweight component that extends Kubernetes' autoscaling capabilities. It provides fine-grained autoscaling for event-driven workloads, allowing applications to scale based on the number of events needing to be processed. + +KEDA bridges the gap between event-driven architectures and Kubernetes' scaling capabilities. It allows for more efficient resource utilization, faster response times to workload changes, and can significantly reduce costs by scaling to zero when there's no work to be done. + +In the modern cloud-native landscape, where applications often need to respond to unpredictable, event-driven workloads, KEDA provides a powerful tool for creating responsive, efficient, and cost-effective Kubernetes deployments. + +### **Objective** + +Design a KEDA-based autoscaling solution for a microservices application that responds efficiently to fluctuating workloads driven by events. + +### **Challenge Steps** + +These are necessary steps that must be followed to complete this challenge. + + +#### 1. KEDA Architecture Design + +1. First, import KEDA into Meshery and expand on the design, identifying the key components of the KEDA architecture including The **KEDA Operator** deployment, the **Metrics Server** etc. Consider how they interact within your Kubernetes cluster and how to properly represent this interaction in your design. + +2. Pay attention to how the KEDA Operator and Metrics Adapter are defined. Consider: + + * Their resource requests and limits. + * Any environment variables or configuration options. + * Service account and RBAC settings. + + +3. Visualize in your design how these components will interact with your Kubernetes cluster's API server, the Horizontal Pod Autoscaler (HPA), and your application deployments. + +#### 2. Application Deployment + +1. Add a sample microservices application to your design. It should contain at least **two** services that could benefit from event-driven scaling. How might these services experience varying loads throughout the day? + +#### 3. KEDA Custom Resource Definitions + +KEDA uses Custom Resource Definitions (CRDs) to define how your services should scale. + +1. Utilize at least two of the following KEDA CRDs in your design: + + * scaledobjects.keda.sh (compulsory) + * scaledjobs.keda.sh + * triggerauthentications.keda.sh + * clustertriggerauthentications.keda.sh + +2. Create ScaledObject resources for your deployed services. + +3. Demonstrate in your design, how an application service would be scaled based on a specific event. + +#### 4. Scaler Implementation + +Scalers are KEDA's sensors, detecting when it's time to scale your services. They're the pulse of your system, constantly monitoring for events that signal a need for more (or fewer) resources. + +1. Implement at least **two** different scalers for your services. + +2. You must include either an **HTTP Scaler** or a **Cron Scaler**. + +3. Choose additional scalers that fit your application's needs. + +**Your design should demonstrate how these scalers respond to various event sources to create a dynamic, event-driven scaling system.** + +#### 5. Identify Event Sources in your Design + +For this task you’ll identify and incorporate at least two different event sources in your design. KEDA supports a wide variety of event sources, including message queues, databases, and time-based triggers. These event sources will act as the signals for your scalers, dictating when and how your services should scale. + +1. Identify at least two event sources in your design. + +2. Clearly define the event source for each scaler, explaining how different types of events in your system can trigger scaling actions. + +#### 6. The HPA Connection + +While KEDA extends Kubernetes' scaling capabilities, it doesn't replace the Horizontal Pod Autoscaler (HPA). Instead, they work together in harmony. + +Demonstrate in your design how KEDA integrates with the HPA. Show the flow of how KEDA detects an event, translates it into a metric, and how the HPA uses this to adjust the number of pods. + +#### 7. Load Generation + +1. Use Meshery's built-in load generator to simulate traffic to your application. + +2. Design a testing scenario that demonstrates how your services scale in response to varying loads. + +### **Evaluation Criteria** + +1. **Functionality**: Your design must be deployable and demonstrate working KEDA autoscaling. + +2. **Scalability**: Effective use of KEDA to handle varying workloads. + +3. **Event Source Diversity**: Incorporation of multiple, relevant event sources. + +4. **Integration**: Clear demonstration of KEDA's interaction with HPA and other Kubernetes components. + +5. **Testing**: Thorough load testing with meaningful analysis of results. + +### **Submission Guidelines** + +1. Provide a detailed architecture diagram of your KEDA implementation. + +2. Include explanations for your choice of event sources and scalers as labels in the design. + +Remember, KEDA allows for scaling based on a wide range of events, from queue lengths to database metrics. Your design should showcase this versatility while addressing practical scaling scenarios for your chosen application. + +Good luck with your KEDA design challenge! \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/content/faq.md b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/content/faq.md new file mode 100644 index 000000000..7a0e8d11f --- /dev/null +++ b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/content/faq.md @@ -0,0 +1,22 @@ +--- +docType: "Chapter" +id: "FAQs" +description: "" +chapterTitle: "FAQs" +title: "FAQs" +weight: 3 +--- + +#### Can I participate in a sample challenge? + +Yes, we recommend that you participate in our sample challenge. + +This challenge enables you to understand how to participate in challenges on Meshery. It comprises detailed information about how questions should be attempted and details about the Meshery judge. + +#### Do I need to register for the contest? + +Yes, in order to participate in a contest you do need to register for the contest with a Meshery account. + +#### How does the ranking work in a contest? + +Each problem has an assigned score. Usually a more challenging problem has a higher score. Your objective is to obtain the highest score with the fastest finish time while making as few mistakes as possible. \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/content/getting-started.md b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/content/getting-started.md new file mode 100644 index 000000000..0c25d0bc6 --- /dev/null +++ b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-auto-scaling-challenge/autoscaling-with-keda/content/getting-started.md @@ -0,0 +1,24 @@ +--- +docType: "Chapter" +id: "About KEDA Challenge" +description: "This competition will challenge you to design and implement event-driven autoscaling for Kubernetes applications using KEDA (Kubernetes Event-driven Autoscaling). You'll learn how to set up KEDA, configure scalers, and optimize autoscaling for various event sources in a microservices architecture." +chapterTitle: "About KEDA Challenge" +title: "About KEDA Challenge" +weight: 1 +--- + +### **Eligibility Criteria** + +This challenge is open for all. + +### **The Rules** + +- This contest is for individuals; teams are not allowed. +- Any competitor found cheating will be disqualified and banned from future contests. + +### **Scoring** +1. Participants are ranked by score. Your score is determined by the following criteria: + * Correct implementation of KEDA scalers (40%) + * Efficiency of autoscaling configuration (30%) + * Integration with at least two different event sources (20%) + * Documentation and explanation of your solution (10%) \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/_index.md b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/_index.md new file mode 100644 index 000000000..6c96907dd --- /dev/null +++ b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/_index.md @@ -0,0 +1,9 @@ +--- +title: "CNCF Observability Challenge with Jaeger" +description: "Join this CNCF Challenge and showcase your skills in designing a distributed tracing architecture using Jaeger." +themeColor: "#3C494F" +banner: "11111111-1111-1111-1111-111111111111/images/jaeger-icon-black.svg" +courses: 1 +weight: 2 +type: learning-paths +--- diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/_index.md b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/_index.md new file mode 100644 index 000000000..7f883f9b3 --- /dev/null +++ b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/_index.md @@ -0,0 +1,27 @@ +--- +docType: "Course" +title: 'Distributed Tracing with Jaeger' +description: "Design an event-driven autoscaling architecture using KEDA." +courseTitle: "Distributed Tracing with Jaeger" +themeColor: "#00B39F" +lectures: 3 +weight: 1 +--- + + +--- + +## Objective +A course to help you setup a service-mesh and start using it to build real-life applications using Meshery +as the cloud native management plane. + +## Prerequisites + +[**Install Jaeger**:](https://www.jaegertracing.io) +Jaeger maps the flow of requests and data as they traverse a distributed system. These requests may make calls to multiple services, which may introduce their own delays or errors. + +**Run Jaeger**: +Your applications must be instrumented before they can send tracing data to Jaeger backend. Check the Client Libraries section for information about how to use the OpenTracing API and how to initialize and configure Jaeger tracers. + +**Manage Jaeger**: +Wrangle your cluster and design with Jaeger. \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/content/description.md b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/content/description.md new file mode 100644 index 000000000..439fae931 --- /dev/null +++ b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/content/description.md @@ -0,0 +1,13 @@ +--- +docType: "Chapter" +id: "About Challenge" +description: "This competition will challenge you to design an architecture diagram that demonstrates how Jaeger can be used to trace requests across a complex microservices architecture. You'll learn how to instrument your code, how to collect and analyze trace data, and how to visualize and interpret the results." +chapterTitle: "About Challenge" +title: "About Challenge" +weight: 2 +--- + +### **Take the Challenge** + +Before you start, grab your timer. Start the clock and start cracking! +[Register now](https://cloud.layer5.io/) diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/content/faq.md b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/content/faq.md new file mode 100644 index 000000000..a21789844 --- /dev/null +++ b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/content/faq.md @@ -0,0 +1,26 @@ +--- +docType: "Chapter" +id: "FAQs" +description: "" +chapterTitle: "FAQs" +title: "FAQs" +weight: 3 +--- + +#### Can I participate in a sample challenge? + +Yes, we recommend that you participate in our sample challenge. + +This challenge enables you to understand how to participate in challenges on Meshery. It comprises detailed information about how questions should be attempted and details about the Meshery judge. + +#### Do I need to register for the contest? + +Yes, in order to participate in a contest you do need to register for the contest with a Meshery account. + +#### How does the ranking work in a contest? + +Each problem has an assigned score. Usually a more challenging problem has a higher score. Your objective is to obtain the highest score with the fastest finish time while making as few mistakes as possible. + +#### Do I have to solve the contest problems in a particular order? + +No, you can solve the problems in any order you like. Feel free to read all of the problems at the beginning of contest. Looking at a problem does not affect your ranking. \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/content/getting-started.md b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/content/getting-started.md new file mode 100644 index 000000000..b3c575eff --- /dev/null +++ b/content/challenges/11111111-1111-1111-1111-111111111111/cncf-observability-challenge-with/distributed-tracing-with-jaeger/content/getting-started.md @@ -0,0 +1,30 @@ +--- +docType: "Chapter" +id: "About Task" +description: "This competition will challenge you to design an architecture diagram that demonstrates how Jaeger can be used to trace requests across a complex microservices architecture. You'll learn how to instrument your code, how to collect and analyze trace data, and how to visualize and interpret the results." +chapterTitle: "About Task" +title: "About Task" +weight: 1 +--- + +### **Eligibility Criteria** + +This challenge is open for all. + +### **The Rules** + +1. This contest is for individuals; teams are not allowed. +2. Any competitor found cheating will be disqualified and banned from future contests. +3. The architecture diagram must include the following components: + - Jaeger Agent + - Jaeger Collector + - Jaeger Query + +### **Scoring** +Participants are ranked by score. Your score is determined by the number of test cases your code submission successfully passes. If two participants have the same score, the tie is broken by the contestant who took the least amount of time to solve the challenges. + +### **Can I participate in a sample challenge?** + +Yes, we recommend that you participate in our sample challenge . + +This challenge enables you to understand how to participate in challenges on Meshery. It comprises detailed information about how questions should be attempted and details about the Meshery judge. \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/_index.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/_index.md deleted file mode 100644 index 15e6831d9..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/_index.md +++ /dev/null @@ -1,13 +0,0 @@ ---- -title: "Working with kubernetes challenge" -description: "Learn how to configure your Kubernetes clusters and manage the lifecycle of your workloads" -themeColor: "#3C494F" -cardImage: "/images/learning-path/kubernetes-icon.svg" -courses: 1 -weight: 2 ---- - - diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/_index.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/_index.md deleted file mode 100644 index d37ea6c84..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/_index.md +++ /dev/null @@ -1,17 +0,0 @@ ---- -docType: "Course" -title: "Ambassador Edge Stack API Gateway with Meshery" -description: "This course will guide you through the process of deploying and visualizing Edge Stack components with Meshery. You will learn how to install and configure the Ambassador API Gateway and explore its integration with Meshery. Additionally, you will gain hands-on experience with two popular service meshes, Istio and Linkerd. By the end of this course, you will have a solid understanding of Edge Stack deployment and be able to leverage Meshery for managing your API gateway and service mesh configurations." -lectures: 4 -courseTitle: "Ambassador Edge Stack API Gateway with Meshery" -themeColor: "#00B39F" -order: 1 -cardImage: "../../../src/images/service-mesh-icons/linkerd-white.svg" -toc: - [ - "introduction", - "edge-stack-configuration", - "design-interpretation", - "conclusion" - ] ---- diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/conclusion.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/conclusion.md deleted file mode 100644 index 80de30467..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/conclusion.md +++ /dev/null @@ -1,24 +0,0 @@ ---- -docType: "Chapter" -id: "conclusion" -chapterTitle: "Conclusion" -description: "Concluding this tutorial, you will gain a comprehensive understanding of how to configure, deploy, and manage the Ambassador Edge Stack with Meshery." -lectures: 4 -title: "Conclusion" -weight: 4 ---- - -{{< chapterstyle >}} - -In this tutorial, you explored the Ambassador Edge Stack (AES) system using Meshery Playground. By leveraging **Kanvas**, you were able to clearly visualize resource relationships, providing a view of the functionalities and roles within the AES system. You should now have a solid understanding of how to configure, deploy, and manage the Ambassador Edge Stack with Meshery. - -Here's a recap of the lessons learned in this course: - -1. The Ambassador Edge Stack (AES) system can be explored using Meshery Playground. -2. Kanvas provides a clear visualization of resource relationships in the AES system. -3. Configuring, deploying, and managing the Ambassador Edge Stack with Meshery is now well understood. - -By following this tutorial, you have gained a comprehensive understanding of the Ambassador Edge Stack and its integration with Meshery. Congratulations on completing the course! - -{{< /chapterstyle >}} - diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/design-interpretation.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/design-interpretation.md deleted file mode 100644 index 4bbc5d007..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/design-interpretation.md +++ /dev/null @@ -1,51 +0,0 @@ ---- -docType: "Chapter" -id: "design-interpretation" -chapterTitle: "Interpreting the Edge Stack Meshery Design" -description: "This chapter explores the relationships between different components in the Ambassador Edge Stack (AES) system using a Kanvas design. It covers the roles and communication ports of each component, as well as the service account roles and relationships within the AES system." -lectures: 4 -title: "Interpreting the Edge Stack Meshery Design" -weight: 3 ---- - -{{< chapterstyle >}} - -

- Exploring the Relationships Between Edge Stack Resources with a Kanvas Design -

- -

Services and Deployments

- -The design below shows the traffic flow between some major components in the the Ambassador Edge Stack (AES) system. - -{{< image src="/images/learning-path/edge-stack/es8.png" width="100%" align="center" alt="" >}} - -The components include ; - -2. edge-stack-agent Deployment -3. edge-stack Deployment -4. edge-stack-admin Service and -5. edge-stack Service - -Let's take a look at the roles of each component and the ports used for communication. - -1. **edge-stack Service**:This serves as the primary entry point for incoming traffic. It listens on ports 80 and 443, handling HTTP and HTTPS traffic respectively. This component routes the incoming requests to the appropriate internal services within the AES system. - -2. **edge-stack-agent**: This is responsible for specific tasks within the AES system. It receives traffic from the edge-stack service on port 80/TCP. The agent handles various operational tasks, including diagnostics and reporting to the Ambassador Cloud. - -3. **edge-stack-admin Service**: This Service provides administrative functions and health checks for the AES system. It communicates with the edge-stack component on port 8877/TCP for administrative purposes. - -4. **edge-stack Deployment**:The edge-stack Deployment component is a core part of the Ambassador Edge Stack, handling the main processing and routing of traffic. It receives traffic from the edge-stack service on port 80/TCP and communicates with the edge-stack-admin component on port 8877/TCP for administrative tasks. - -

Service Account Roles

- -{{< image src="/images/learning-path/edge-stack/es9.png" width="100%" align="center" alt="" >}} -The diagram above shows one of the role assignments and service account relationships within -the Ambassador Edge Stack (AES) system. You can see that the Service Account (edge-stack) is -linked to both the ClusterRole (edge-stack) and the Role (edge-stack-apiext) through ClusterRoleBinding -and RoleBinding. - -With the help of Kanvas, these connections become clear and easy to understand. - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-deployment-service.js" id="embedded-design-7b01cebf-b0f9-4c11-87e7-612d8fad10c8" >}} -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/edge-stack-configuration.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/edge-stack-configuration.md deleted file mode 100644 index 01224837b..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/edge-stack-configuration.md +++ /dev/null @@ -1,138 +0,0 @@ ---- -docType: "Chapter" -id: "edge-stack-configuration" -chapterTitle: "Edge Stack Configuration" -description: "This chapter covers the configuration of the Edge Stack, including importing and deploying Edge Stack Custom Resource Definitions (CRDs) and YAML files. You will learn how to configure the necessary Ambassador Cloud license and set up essential components like Listener and Mapping resources. Finally, you will deploy a sample Quote service application to route traffic through Edge Stack." -lectures: 4 -weight: 2 -title: "Edge Stack Configuration" ---- - -{{< chapterstyle >}} - -In this chapter, you will import and deploy Edge Stack Custom Resource Definitions (CRDs) and YAML files. You'll learn how to configure the necessary Ambassador Cloud license and set up essential components like Listener and Mapping resources. Finally, you'll deploy a sample Quote service application to route traffic through Edge Stack. - -

Steps

- -

Import Edge Stack CRD YAML and Deploy

- -The Edge Stack CRD YAML file typically contains the definitions for custom resources used by Edge Stack. These definitions include the schemas and validation rules for resources like Mappings, Hosts, TLSContexts, RateLimits, Filters, and more. These custom resources allow you to define and manage the various aspects of your API gateway configuration, such as routing, authentication, rate limiting, and TLS settings, directly within your Kubernetes cluster. - -1. In the left sidebar, click on the upward arrow symbol (import icon) to import the file into Meshery. - -2. In the modal that appears: - - Enter a name for your design in the **Design File Name** field (e.g. _Edge-stack-crd_). - - Select _Kubernetes Manifest_ from the **Design Type** dropdown menu. - - Choose **Url upload** for the upload method, and paste in the [Edge-Stack-crd](https://app.getambassador.io/yaml/edge-stack/3.11.0/aes-crds.yaml) YAML link. - - Then, click on **Import**. - -{{< image src="/images/learning-path/edge-stack/es1.png" width="100%" align="center" alt="" >}} - -3. Click on the name of the design on the Designs tab to display the visual representations of the various Kubernetes resources and their relationships on the canvas. - -4. Click **Actions** in the top right corner and click on Deploy (double tick). - -5. To check the status of your deployment, click on the notification icon on the top right corner. - -{{< image src="/images/learning-path/edge-stack/es2.png" width="100%" align="center" alt="" >}} - -6. Click on **Open In visualizer** to navigate to the Visualize section and see a pre-filtered view of the deployed resources in the cluster. - -{{< image src="/images/learning-path/edge-stack/es3.png" width="100%" align="center" alt="" >}} - -

Import the Edge Stack YAML

- -Now that the CRDs have been deployed, go ahead to deploy the main Edge Stack Configuration. - -1. Follow the previous Steps to Import the [Edge Stack YAML](https://app.getambassador.io/yaml/edge-stack/3.11.0/aes.yaml) into Kanvas with the name _Edge-Stack_. - -{{< image src="/images/learning-path/edge-stack/es4.png" width="100%" align="center" alt="" >}} - -2. You can use the **Group Components** icon on the dock below to group resources based on shared labels or annotations. - -{{< image src="/images/learning-path/edge-stack/es5.png" width="100%" align="center" alt="" >}} - -

Configure Edge Stack License

- -Ambassador Edge Stack requires a valid license to operate. Generate your [license token](https://app.getambassador.io/cloud/edge-stack/license/new) to establish a secure connection between Edge Stack and Ambassador Cloud. - -1. Complete the steps on the Ambassador Cloud to generate your license token, then copy the token. Be sure to convert it into **base64** format. You can use an online tool for this conversion. - -2. Click on the Secret component on the design canvas and input the token. - -{{< image src="/images/learning-path/edge-stack/es6.png" width="100%" align="center" alt="" >}} - -

Deploy Edge Stack

- -1. Click **Actions** in the top right corner and click on Deploy (double tick). - -2. Click on **Open In visualizer** to navigate to the Visualize section and see a pre-filtered view of the deployed resources in the cluster. - -{{< image src="/images/learning-path/edge-stack/es10.png" width="100%" align="center" alt="" >}} - -

Listener Custom Resource

- -The Listener Custom Resource tells Ambassador Edge Stack what port to listen on. - -1. Copy the following the YAML and save it to a file called _listener.yaml_ , then import it into Kanvas. - -```YAML ---- -apiVersion: getambassador.io/v3alpha1 -kind: Listener -metadata: - name: edge-stack-listener-8080 - namespace: ambassador -spec: - port: 8080 - protocol: HTTP - securityModel: XFP - hostBinding: - namespace: - from: ALL ---- -apiVersion: getambassador.io/v3alpha1 -kind: Listener -metadata: - name: edge-stack-listener-8443 - namespace: ambassador -spec: - port: 8443 - protocol: HTTPS - securityModel: XFP - hostBinding: - namespace: - from: ALL -EOF - -``` - -2. Deploy the resource on Kanvas. - -

Mapping Resource

- -Create a Mapping configuration that instructs Edge Stack on how and where to route traffic. In the YAML file below, any request coming to the specified _hostname_ with the _prefix_ /backend/ will be directed to the _quote service_. - -Copy the following the YAML and save it to a file called _mapping.yaml_ , then import it into Kanvas. - -```YAML -apiVersion: getambassador.io/v3alpha1 -kind: Mapping -metadata: - name: quote-backend -spec: - hostname: "*" - prefix: /backend/ - service: quote - docs: - path: "/.ambassador-internal/openapi-docs" - -``` - -

Deploy Quote Service

- -Next, import the [Quote Service YAML](https://app.getambassador.io/yaml/v2-docs/3.9.1/quickstart/qotm.yaml) and deploy it on Kanvas. This step will create the necessary deployment and service resources for the Quote service within your Kubernetes cluster, allowing you to see how Edge Stack manages and routes traffic to this backend service. - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-edge-stack.js" id="embedded-design-d429e684-c42a-4c14-816b-b4dddb4b6d40" >}} - -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/introduction.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/introduction.md deleted file mode 100644 index 2c36f941e..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/ambassador-edge-stack-api-gateway-with-meshery/edge/introduction.md +++ /dev/null @@ -1,61 +0,0 @@ ---- -docType: "Chapter" -id: "introduction" -chapterTitle: "Introduction" -description: "Ambassador Edge Stack is a powerful API gateway built on Envoy Proxy. It simplifies the configuration, deployment, and management of APIs in Kubernetes environments. With features like automatic TLS, authentication, rate limiting, load balancing, and observability, Ambassador Edge Stack ensures scalability and flexibility for high traffic volumes and distributed requests across multiple services in your cluster." -lectures: 4 -title: "Exploring Edge Stack with Meshery Playground" -weight: 1 ---- - -{{< chapterstyle >}} - -

Overview

- -In this tutorial, you will explore Edge Stack using Meshery Playground. You'll get hands-on experience importing YAML files that contain Edge Stack configurations and Custom Resource Definitions (CRDs). - -You'll use Kanvas to view, configure, and deploy Kubernetes resources, including Edge Stack with its custom resources and a sample application. Additionally, you'll leverage Meshery's visualization tool to filter the deployed resources in your cluster. - -

Objectives

- -This tutorial will guide you through exploring Edge Stack using Meshery Playground. You'll cover: - -1. **Importing YAML Files**: Learn how to import YAML files containing Edge Stack configurations and CRDs (Custom Resource Definitions) into Kanvas. -2. **Design Configuration**: Configure a Kubernetes component on the Playground Canvas. -3. **Deployment**: Deploy Edge Stack alongside a sample application and custom resources. -4. **Visualization**: Get hands-on with Kanvas to understand the components and their interactions within Edge Stack. -5. **Design Interpretation**: Explore some of the relationships between Edge Stack resources with a Kanvas design, explaining their functionalities and roles within the system. - -

Meshery Playground and Kanvas

-**Meshery Playground** is an interactive and collaborative live cluster environment that simplifies -the deployment process and enhances user experience by providing visual tools for managing -Kubernetes resources. - -[**Kanvas**](https://docs.layer5.io/kanvas/) is a visual tool within Meshery that allows users to interact with and manage Kubernetes resources. It provides a graphical interface for viewing, configuring, and deploying resources, making it easier to understand the relationships and interactions between different components in a Kubernetes cluster. - -If this is your first time working with Meshery Playground, consider starting with the [Exploring Kubernetes Pods with Meshery Playground](https://docs.meshery.io/guides/tutorials/kubernetes-pods) tutorial first. - -

Ambassador Edge Stack

- -Ambassador [Edge Stack](https://www.getambassador.io/products/edge-stack/api-gateway) is a Kubernetes-native API Gateway built on [Envoy Proxy](https://www.envoyproxy.io/). It streamlines Kubernetes workflows for configuration, deployment, and management of APIs, efficiently snd securely managing high traffic volumes and distributing requests across multiple services in your cluster. - -The "stack" includes security functionalities such as automatic TLS, authentication, and rate limiting, as well as load balancing, ingress control and observability all integrated to ensure scalability and flexibility in Kubernetes environments. - -

Prerequisites

- -- Basic understanding of Kubernetes concepts. -- Access to the _Meshery Playground_. If you don't have an account, sign up at [Meshery Playground](https://play.meshery.io/). -- [Ambassador Cloud](https://www.getambassador.io/solutions/ambassador-cloud) account. - -

Access Meshery Playground

- -1. Log in to the [Meshery Playground](https://cloud.layer5.io/) using your credentials. -2. Click **Explore** in the Cloud Native Playground tile to navigate to _Kanvas_. - - - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-edge-stack.js" id="embedded-design-d429e684-c42a-4c14-816b-b4dddb4b6d40" >}} - - - -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/_index.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/_index.md deleted file mode 100644 index 1eef4fe8e..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/_index.md +++ /dev/null @@ -1,34 +0,0 @@ ---- -docType: "Course" -title: "Deploying WordPress and MySQL with Persistent Volumes with Meshery" -description: "Learn how to deploy WordPress and MySQL with persistent volumes with Meshery Playground" -lectures: 7 -courseTitle: "Deploying WordPress and MySql with Persistent Volumes with Meshery" -themeColor: "#00B39F" -order: 1 -cardImage: "../../../src/images/service-mesh-icons/linkerd-white.svg" -meshesYouLearn: - [ - { - imagepath: "../../../src/images/service-mesh-icons/istio.svg", - name: "Istio" - }, - { - imagepath: "../../../src/images/service-mesh-icons/linkerd.svg", - name: "Linkerd" - } - ] -toc: - [ - "introduction", - "import-designs", - "configure-components", - "group-components", - "deploy", - "visualize", - "conclusion" - ] ---- - -A course to help you deploy wordpress and MySQL Database with persistent volumes with Meshery Playground. - diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/conclusion.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/conclusion.md deleted file mode 100644 index e5a5d1693..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/conclusion.md +++ /dev/null @@ -1,16 +0,0 @@ ---- -docType: "Chapter" -id: "conclusion" -chapterTitle: "Conclusion" -description: "" -lectures: 12 -weight: 7 -title: "Conclusion" ---- - -{{< chapterstyle >}} - - -Congratulations! You’ve successfully completed the tutorial on deploying a WordPress site and MySQL database with Persistent Volumes using Meshery Playground. This hands-on experience should have given you valuable insights into importing manifest files, visualizing resources, creating persistent volumes, and managing deployments in Meshery Playground. - -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/configure-components.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/configure-components.md deleted file mode 100644 index 4cd8c740a..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/configure-components.md +++ /dev/null @@ -1,99 +0,0 @@ ---- -docType: "Chapter" -id: "configure-components" -chapterTitle: "Create and Configure Kubernetes Components" -description: "In this section you will create and configure Persistent Volumes, Persistent Volume Claims and a Secret for the Database." -lectures: 12 -weight: 3 -title: "Configure Components" ---- - -{{< chapterstyle >}} - -

Create and Configure Secret for MySQL Database

- -In this step, you create a Kubernetes secret component for the MySQL database. This is necessary because the configuration below is in the environment variables section of the mysql-deployment YAML file. - -```yaml -env: - - name: MYSQL_ROOT_PASSWORD - valueFrom: - secretKeyRef: - name: mysql-pass - key: password -``` - -Before you proceed, choose a password and convert it into base64 format. You can use an online tool for this conversion. For this example, the password is `password` and its base64 encoding is `cGFzc3dvcmQ=`. - -1. Click on the Kubernetes icon on the dock, search for `secret`, and click on it or drag it to the canvas. - -
-{{< image src="/images/learning-path/sql/wp8.png" width="100%" align="center" alt="" >}} - -_Figure: Create secret component_ - -2. Click on the Secret component to open the configuration window. - - - Set the _name_ as `mysql-pass` - - Set the _Type_ as `Opaque` - - Click **+** next to Data and add the secret as a key-value pair `password:cGFzc3dvcmQ=` - -
-{{< image src="/images/learning-path/sql/wp9.png" width="100%" align="center" alt="" >}} - -_Figure: Configure secret_ - -3. Click outside the window to close the configuration tab. - -

Create Persistent Volumes

- -MySQL and WordPress each require a [Persistent Volume (PV)](https://kubernetes.io/docs/concepts/storage/persistent-volumes/) to store their data. - -For this tutorial, you will use the `manual` StorageClassName and set the Persistent Volume to use the `hostPath` type. - -Please note that using `hostPath` for Persistent Volumes is generally not recommended for production environments because it ties the volume to the node's filesystem, which can lead to data loss if the node fails. However, you can use it in this tutorial for development purposes. - -1. Click on the Kubernetes icon on the dock, search for `Persistent Volume`, and select it. Create two PVs. - -
-{{< image src="/images/learning-path/sql/wp10.png" width="100%" align="center" alt="" >}} - -_Figure: Create persistent volume_ - -2. Click on the wordpress PV to open the configuration window. - - - Change the "name" to `wp-pv` - - Set the "StorageClassName" as `manual` - - Click **+** next to "AccessMode" and enter `ReadWriteOnce` - -
-{{< image src="/images/learning-path/sql/wp11.png" width="100%" align="center" alt="" >}} - -_Figure: Configure persistent volume_ - - - Scroll down to "Capacity" and enter the key pair `storage:20Gi` - -
-{{< image src="/images/learning-path/sql/wp12.png" width="100%" align="center" alt="" >}} - -_Figure: Persistent volume capacity_ - - - Scroll down to "Hostpath" and input `mnt/data/wp-pv` for the _path_ and `DirectoryOrCreate` for the _type_. - -
-{{< image src="/images/learning-path/sql/wp13.png" width="100%" align="center" alt="" >}} - -_Figure: Persistent volume hostpath_ - -3. Repeat similar steps for the MySQL Persistent Volume - - - Click on the MySQL PV to open the configuration window. - - Change the "name" to `mysql-pv` - - Set the "StorageClassName" to `manual` - - Click **+** next to "AccessMode" and set it to `ReadWriteOnce` - - Scroll down to "Capacity" and enter the key pair `storage:20Gi` - - Scroll down to "Hostpath" and input `mnt/data/mysql-pv` for the _path_ and `DirectoryOrCreate` for the _type_. - -4. Click on `wp-pv-claim` and `mysql-pv-claim` and set their "StorageClassName" as `manual`. - -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/deploy.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/deploy.md deleted file mode 100644 index 7fd40dca4..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/deploy.md +++ /dev/null @@ -1,52 +0,0 @@ ---- -docType: "Chapter" -id: "deploy" -chapterTitle: "Validate and Deploy Resources" -description: "In this section you will validate your design and deploy the resources to a Kubernetes cluster" -lectures: 12 -weight: 5 -title: "Deploy Resources" ---- - -{{< chapterstyle >}} - -

Deploy the Resources

- -1. Click `Actions` in the top right corner and click on `Deploy`. - -
-{{< image src="/images/learning-path/sql/wp15.png" width="100%" align="center" alt="" >}} - -_Figure: Actions dropdown menu_ - -2. The design will be validated to make sure there are no errors. - -
-{{< image src="/images/learning-path/sql/wp16.png" width="100%" align="center" alt="" >}} - -_Figure: Validate design_ - -3. Choose the Kubernetes cluster you want to deploy to. - -
-{{< image src="/images/learning-path/sql/wp17.png" width="100%" align="center" alt="" >}} - -_Figure: Choose deployment Environment_ - - **_Note_**: The Meshery Playground is connected to live Kubernetes cluster(s) and allows users full control over these clusters but you can also have the option to add your own Kubernetes cluster to the Playground. - -4. Finally click `Deploy` to deploy the application to the cluster. - -
-{{< image src="/images/learning-path/sql/wp18.png" width="100%" align="center" alt="" >}} - -_Figure: Deploy resources_ - -5. To check the status of your deployment, click on the notification icon on the top right corner. You can click on `Open In visualizer` to navigate to the Visualize section or follow the steps below. - -
-{{< image src="/images/learning-path/sql/wp22.png" width="100%" align="center" alt="" >}} - -_Figure: Deploy resources_ - -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/group-components.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/group-components.md deleted file mode 100644 index 4f697eb2e..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/group-components.md +++ /dev/null @@ -1,42 +0,0 @@ ---- -docType: "Chapter" -id: "group-components" -chapterTitle: "Add labels and Group Components" -description: "In this section you will add labels to components and learn how to group them." -lectures: 12 -title: "Group Components" -weight: 4 ---- - -{{< chapterstyle >}} - -

Add Labels

- -To make it easier to filter and manage your resources during visualization, add labels to all of them. - -You can also choose to use the existing label, `app:wordpress`, but a new one, `dev:tutorial`, is recommended for this tutorial to prevent your resources from getting mixed up with others in the public playground cluster. - -1. Click on the label icon. -2. Click the **+** sign next to Labels. -3. Add the label `dev:tutorial`. -4. Do this for **all** the resources on the canvas. - -
-{{< image src="/images/learning-path/sql/wp14.png" width="100%" align="center" alt="" >}} - -_Figure: Add label_ - -5. Now click on `Save As` and save the design. - -

Group Components

- -The _**Group Components**_ icon on the dock below allows you to group resources based on shared labels or annotations. - -This functionality aids in visualizing the relationships between various resources, making it easier to manage them, troubleshoot issues, and understand the overall cluster architecture. - -
-{{< image src="/images/learning-path/sql/wp21.png" width="100%" align="center" alt="" >}} - -_Figure: Group Components_ - -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/import-designs.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/import-designs.md deleted file mode 100644 index 7f3d71e8b..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/import-designs.md +++ /dev/null @@ -1,73 +0,0 @@ ---- -docType: "Chapter" -id: "import-designs" -chapterTitle: "Import Design Files and Merge" -description: "Here we will import the design files in Meshery Playground and learn how to merge designs." -lectures: 12 -title: "Import Designs" -weight: 2 ---- - -{{< chapterstyle >}} - -1. In the left sidebar, click on the upward arrow symbol (import icon) to import the designs into Meshery. -2. In the modal that appears: - - Enter a name for your design in the "Design File Name" field (e.g. `mysql-deployment`). - - Select `Kubernetes Manifest` from the "Design Type" dropdown menu. - -
-{{< image src="/images/learning-path/sql/wp1.png" width="100%" align="center" alt="" >}} - -_Figure: Import modal_ - -- Choose `File Upload` for the upload method, and select the file you just downloaded. -- Then, click on `Import`. -
- {{< image src="/images/learning-path/sql/wp2.png" width="100%" align="center" alt="" >}} - -_Figure: Import mysql-deployment_ - -3. Under the "Designs" tab, you will see the successfully imported `mysql-deployment` design. - - Clicking on the names of the designs on the `Designs` tab displays the visual representations of the various Kubernetes resources and their relationships on the canvas. - -
- {{< image src="/images/learning-path/sql/wp3.png" width="100%" align="center" alt="" >}} - -_Figure: Imported designs on canvas_ - -4. Now, follow the same steps to import the `wordpress-deployment` file. - -
-{{< image src="/images/learning-path/sql/wp4.png" width="100%" align="center" alt="" >}} - -_Figure: wordpress-deployment_ - -

Merging the Designs

- -Next, you will combine the WordPress and MySQL designs into a single design file. By merging these designs, you can manage and deploy both resources together. - -To merge the MySQL deployment design with the WordPress deployment design: - -1. Click and drag the `mysql-deployment` design from the left panel and drop it onto the design canvas of the `wordpress-deployment`. - -
-{{< image src="/images/learning-path/sql/wp5.png" width="100%" align="center" alt="" >}} - -_Figure: drag and drop design_ - -2. This action will open a merge modal asking if you want to merge the design, Click on `Merge`. - -
-{{< image src="/images/learning-path/sql/wp6.png" width="100%" align="center" alt="" >}} - -_Figure: merge modal_ - -3. Click on `Save As` and enter `wordpress-mysql-deployment` as the new file name. - -
-{{< image src="/images/learning-path/sql/wp7.png" width="100%" align="center" alt="" >}} - -_Figure: save design_ - -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/introduction.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/introduction.md deleted file mode 100644 index 3c5e2115c..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/introduction.md +++ /dev/null @@ -1,47 +0,0 @@ ---- -docType: "Chapter" -id: "introduction" -chapterTitle: "Introduction" -description: "Get started with Meshery playground" -title: "Deploying WordPress and MySQL with Persistent Volumes with Meshery" -lectures: 12 -weight: 1 ---- - -{{< chapterstyle >}} - -In this tutorial, you will learn how to deploy a **WordPress site and a MySQL database with Persistent Volumes** using Meshery Playground. Meshery Playground is an interactive and collaborative live cluster environment that simplifies the deployment process and enhances user experience by providing visual tools for managing Kubernetes resources. - -> **NOTE:** If this is your first time working with Meshery Playground, consider starting with the [Exploring Kubernetes Pods with Meshery Playground](https://docs.meshery.io/guides/tutorials/kubernetes-pods) tutorial first. - -

Prerequisites

- -- Basic understanding of Kubernetes concepts. -- Access to the _Meshery Playground_. If you don't have an account, sign up at [Meshery Playground](https://play.meshery.io/). - -

Lab Scenario

- -- Import the WordPress and MySQL manifest files into Meshery Playground. -- Create persistent volumes and a secret for the resources using the visual tools provided by Meshery. -- Deploy these resources on the playground. - -In this lab, you will import the WordPress and MySQL manifest files into Meshery Playground. You will visualize these Kubernetes resources and create persistent volumes for them using the visual tools provided by Meshery. Finally, you will deploy these resources on the Playground. - -

Objective

- -Learn how to import manifest files, visualize Kubernetes resources, create new resource components, and deploy the application using Meshery Playground. - -

Steps

- -

Download the Kubernetes Configuration Files

- -Go ahead and download these yaml files [mysql-deployment.yaml](https://kubernetes.io/examples/application/wordpress/mysql-deployment.yaml) and [wordpress-deployment.yaml](https://kubernetes.io/examples/application/wordpress/wordpress-deployment.yaml) - -These YAML files contain the Service definitions, Persistent Volume Claims, and Deployment configurations for the WordPress site and the MySQL database. - -

Access Meshery Playground

- -1. Log in to the [Meshery Playground](https://cloud.layer5.io/) using your credentials. On successful login, you should be at the dashboard. Press the **X** on the _Where do you want to start?_ popup to close it (if required). -2. Click **Explore** in the Cloud Native Playground tile to navigate to _Kanvas_ - -{{< /chapterstyle >}} \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/visualize.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/visualize.md deleted file mode 100644 index 235b7409f..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/deploying-wordpress-and-mysql-with-persistent-volumes-with-meshery/sql/visualize.md +++ /dev/null @@ -1,56 +0,0 @@ ---- -docType: "Chapter" -id: "visualize" -chapterTitle: "Visualize Deployed Resources" -description: "In this section you will use the Visualize tool to see the resources in the cluster" -lectures: 12 -title: "Visualize Resources" -weight: 6 ---- - -{{< chapterstyle >}} - -

Visualizing the Deployed Resources

- -To view the resources deployed, use the Visualize section of the _Kanvas_. In this section, you can apply filters to display the specific resources you want to see. - -1. Move to the Visualize tab. -2. Click the filter icon and choose the appropriate filters - - - For "Kinds" select `Deployment`, `Service`, `PersistentVolume`, `PersistentVolumeClaim` and `Secret` - - For the "label" select `dev=tutorial` - -3. You can also use the icons on the right sidebar to filter the resources. - - After selecting your filters, you should see a view displaying only your relevant resources, as shown in the image below. - -
- {{< image src="/images/learning-path/sql/wp19.png" width="100%" align="center" alt="" >}} - -_Figure: Filter resources_ - -

Resource Details

- -You can click on any resource to view more details about it in the "Details" section on the right sidebar. - -**Deployment** - -
-{{< image src="/images/learning-path/sql/wp23.png" width="100%" align="center" alt="" >}} - -_Figure: Get more details about deployment_ - -**Service** - -The Service details only display the cluster IP for now. So there is no way to access the application externally. - -
-{{< image src="/images/learning-path/sql/wp20.png" width="100%" align="center" alt="" >}} - -_Figure: Get more details about service_ - -

Deleting Resources

- -To delete the resources, use the `Undeploy` option from the Action dropdown in the _Design_ tab. - -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/_index.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/_index.md deleted file mode 100644 index 22c2a6937..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/_index.md +++ /dev/null @@ -1,21 +0,0 @@ ---- -docType: "Course" -title: "Explore Dapr with Meshery" -description: "Learn how Dapr works by deploying Dapr and sample applications in a Kubernetes Cluster using Meshery" -lectures: 4 -courseTitle: "Explore Dapr with Meshery" -themeColor: "#00B39F" -order: 4 -cardImage: "../../../src/images/service-mesh-icons/linkerd-white.svg" - -toc: - [ - "introduction", - "deploy-dapr-control-plane", - "deploy-redis", - "deploy-dapr-statestore-component", - "deploy-python-and-nodejs-application", - "view-application-logs", - "conclusion" - ] ---- \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/conclusion.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/conclusion.md deleted file mode 100644 index 149afcc9b..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/conclusion.md +++ /dev/null @@ -1,19 +0,0 @@ ---- -docType: "Chapter" -id: "conclusion" -chapterTitle: "Conclusion" -description: -title: "Conclusion" -lectures: 4 -weight: 7 ---- - -{{< chapterstyle >}} -Congratulations! You have reached the end of this course on understanding how Dapr works in a Kubernetes cluster, using Meshery as a visual guide. Throughout this course, you learned how to import Dapr, Redis, and application configuration files into Meshery and visualize the resources and their relationships. - -You successfully created and configured a Dapr state store component using Meshery. You deployed the designs and visualized the deployed resources in the cluster using Operator mode. Additionally, you viewed the Dapr sidecars and observed the resources deployed in the dapr-system and default namespaces. - -Finally, you streamed the logs and observed the API calls, gaining a deeper understanding of how Dapr's APIs, such as the state management API and service invocation API, work together to facilitate seamless inter-service communication and efficient management of application state. - -Well done on completing this course and enhancing your knowledge of Dapr and Meshery! -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-dapr-control-plane.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-dapr-control-plane.md deleted file mode 100644 index d098475ff..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-dapr-control-plane.md +++ /dev/null @@ -1,109 +0,0 @@ ---- -docType: "Chapter" -id: "deploy-dapr-control-plane.mdx" -chapterTitle: "Deploy Dapr Control Plane" -description: "This chapter takes you through the import, exploration and deployment of Dapr control plane components" -lectures: 4 -title: "Deploy Dapr Control Plane" -weight: 2 ---- -{{< chapterstyle >}} - -The [Dapr control plane](https://docs.dapr.io/concepts/dapr-services/) is a set of services responsible for managing and orchestrating the runtime and configuration of Dapr. The control plane ensures the smooth operation, deployment, and management of Dapr sidecars and their interactions within a microservices architecture. - -

Steps

- - -

Import Dapr Helm Chart

- -1. In the left sidebar, click the upward arrow symbol(import icon) to import the file into Meshery. - -1. In the modal that appears: - - Enter a name for your design in the **Design File Name** field (e.g. _DAPR_). - - Select _Helm Chart_ from the **Design Type** dropdown menu. - - Navigate to the [Dapr Helm Chart page](https://artifacthub.io/packages/helm/dapr/dapr/1.14.0-rc.4?modal=install) on Artifact Hub. - - Right-click **this_link** at the bottom of the installation modal to copy the link address. - - Paste the copied link in the **URL** field. - - Then, click **Import**. - - {{< image src="/images/learning-path/dapr/dapr-helm.png" width="100%" align="center" alt="" >}} - -1. On the Designs tab on the left, click on the **DAPR** design you just imported. This will display the various Kubernetes resource components required for deploying the Dapr control plane on the canvas. - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-dapr.js" id="embedded-design-7d183e77-09e1-4b69-a5ee-3e3870e9c5f4" >}} - -

Design Interpretation

- -From the design above, several key components that constitute the **Dapr control plane** can be observed, including: - -- **Dapr Sidecar Injector**: Automatically injects Dapr sidecars into the application pods. -- **Dapr Operator**: Manages the lifecycle of Dapr components and configurations within the Kubernetes cluster. -- **Dapr Placement Service**: Provides service discovery and routing for stateful applications, ensuring that stateful actors are placed correctly. -- **Dapr Sentry**: Handles certificate authority and manages secure communication between Dapr instances. - -Let’s take a closer look at some of the relationships between these components. - -**Statefulsets, Deployments, and Services** - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-dapr-deployments.js" id="embedded-design-f6439589-1722-4fbc-b0e5-49f8d7c0ab17" >}} - -The triangles represent services, the rectangles represent deployments, and the cylinder icons represent statefulsets. Arrows indicate that a service is associated with a deployment/statefulset, exposing network access to it, indicative of an [Edge-Network](https://docs.meshery.io/concepts/logical/relationships#1-edge---network) relationship. The ports exposed by each service are shown at the ends of the arrows. To learn more about how to identify these components, see [Component Shape Guide](). - -To briefly take a look at one of these network relationships, click on the dapr-operator container in the deployment and its service to open their configuration tabs. - -{{< image src="/images/learning-path/dapr/relationship.png" width="100%" align="center" alt="" >}} - -From the diagram above, the container within the `dapr-operator` deployment is configured to expose Container port **6500**. The `dapr-api` service listens on port **443** and forwards incoming traffic to Target Port **6500**. This is why the arrow is labeled with **443/TCP**. - -This illustrates how exposed ports are mapped to their corresponding services within a deployment configuration. - -**Roles, ClusterRoles, and ServiceAccountss** - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-dapr-roles.js" id="embedded-design-79476480-b3b3-4e47-8805-de2cd5735bb8" >}} - -These resources represent Roles, ClusterRoles, ServiceAccounts, and other necessary RBAC configurations that the Dapr control plane requires within the cluster. An [Edge-permission](https://docs.meshery.io/concepts/logical/relationships#3-edge---permission) relationship exists between some of these components, which are bound through RoleBindings and ClusterRoleBindings. - - -**Custom Resource and Custom Resource Definitions** - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-dapr-crds.js" id="embedded-design-7eed863e-a37c-493f-a7b6-61e4b29bb678" >}} - -Dapr leverages several Custom Resource Definitions (CRDs) to allow users manage and define its configuration and operation.The key custom resources are **Configurations**, **Components**, **Resiliency**, **Subscriptions**, **HTTPEndpoints**. - -The **daprsystem** icon above is a custom resource of kind **Configuration**. It is used to configure global settings for Dapr components within a Kubernetes cluster. - -The **Dapr State Store component** that manages Redis, as we mentioned before in the introduction, is a custom resource of kind **Component**. The Component CRD defines the configuration for external resources such as state stores, pub/sub brokers, and secret stores. - -We can also explore relationships through grouped components. - -**Grouped Components** - -{{< image src="/images/learning-path/dapr/grouped.png" width="100%" align="center" alt="" >}} - -Click on the **Group Components** icon on the dock at the bottom of the canvas to group resources based on shared labels or annotations. - -Using Meshery's grouping feature, we can organize related components, enhancing our understanding of the Dapr control plane within the Kubernetes environment. Let’s take a detailed look at the first group in the image above. It is the Dapr-sidecar-injector group consisting of these components: - -1. Deployment -1. Service, and -1. Mutating Webhook Configuration - -When a new application pod is deployed, the **dapr-sidecar-injector deployment** intercepts the pod creation request using the **Mutating Webhook Configuration** and programmatically attaches the Dapr sidecar to the pod based on configured annotations. - -The grouping of these components illustrates their interconnections, enhancing our ability to visualize and understand how various parts function together within the cluster. - -

Deploy Dapr

-1. The Dapr control plane has to deployed in the **dapr-system** namespace. Click on the namespaced components(deployments, services etc) to open up the configuration tab. Then change the namespace from **default** to **dapr-system**. - -1. To deploy, click **Actions** in the top right corner and click on Deploy (double tick). To learn about deploying Designs in Meshery, See Chapter [Deploying Meshery Designs](https://cloud.layer5.io/academy/learning-paths/mastering-meshery/introduction-to-meshery). - -1. After deployment, Click on **Open In Visualizer** to see the pre-filtered view of the deployed resources in the cluster. - -1. In **Visualizer** mode, use the filter to adjust the views of the resources in the cluster. - - For **View Selector** select **Single Node**. - - For **Kinds** select the resources you want to see including _Deployments, Pods, Services, Statefulset, Secret, Replicaset, Endpoints and Endpoint slices_. - -{{< image src="/images/learning-path/dapr/dapr-visualizer.png" width="100%" align="center" alt="" >}} - -Using Meshery, we have visualized the components of the Dapr control plane, explored their relationships, and successfully deployed Dapr. Our next step is to integrate the Redis store into our architecture. -{{< /chapterstyle >}} \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-dapr-statestore-component.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-dapr-statestore-component.md deleted file mode 100644 index f3f9d458c..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-dapr-statestore-component.md +++ /dev/null @@ -1,48 +0,0 @@ ---- -docType: "Chapter" -id: "deploy-dapr-statestore-component.mdx" -chapterTitle: "Deploy Dapr StateStore Component" -description: -title: "Deploy Dapr StateStore Component" -lectures: 4 -weight: 4 ---- -{{< chapterstyle >}} -

Create, Configure and Deploy Dapr Redis State Store Component

- -Following the deployment of the Redis state store, we will use Meshery to create and configure the Dapr state store component. This involves specifying essential details, including the redisHost and redisPassword fields in the Dapr component configuration, which tell Dapr where to find the Redis server and how to authenticate. - -This setup ensures that Dapr connects to the correct Redis instance, allowing it to handle state management seamlessly without direct involvement from your application. - -

Search for Component

- -1. On the Dock at the bottom of the design canvas, click on **Components**. -1. Search for "dapr". -1. Click on the drop-down and drag and drop **component** to the design canvas. This is the Dapr component custom resource we discussed when learning about the Dapr control plane. - -{{< image src="/images/learning-path/dapr/drag-component.png" width="100%" align="center" alt="" >}} -

Configure State Store and Deploy

- -Now you can start configuring the Dapr state-store. - -1. Click on the component to open the configuration tab. -1. Enter _state-store_ as the **name**. -1. Enter _kubernetes_ in the **Secret store** field. -1. Enter _state.redis_ in the **Type** field. -1. Enter _v1_ in the **version** field. - -{{< image src="/images/learning-path/dapr/state-store.png" width="100%" align="center" alt="" >}} - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-statestore.js" id="embedded-design-f0b9088c-ab17-41ee-9400-fcfc5f4d59a8" >}} - -1. Click on the **metadata** drop-down and begin to fill in the info. -1. For **Name**, enter _redisHost_. -1. For **Value**, enter _redis-master.default.svc.cluster.local:6379_. -1. Under **Secret Key Ref**, enter the pair _redis:redis-password_. - -{{< image src="/images/learning-path/dapr/metadata.png" width="100%" align="center" alt="" >}} -5. Click the **Actions** button and deploy. - -Next we will deploy the Python and Node.js applications. - -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-python-and-nodejs-application.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-python-and-nodejs-application.md deleted file mode 100644 index 90db61d38..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-python-and-nodejs-application.md +++ /dev/null @@ -1,46 +0,0 @@ ---- -docType: "Chapter" -id: "deploy-python-and-nodejs-application.mdx" -chapterTitle: "Deploy Python and NodeJS application" -description: -title: "Deploy Python and NodeJS application" -lectures: 4 -weight: 5 ---- -{{< chapterstyle >}} - -

Deploy Node.js Application

- -1. Clone [this](https://github.com/dapr/quickstarts.git) repo and cd into **quickstarts/tutorials/hello-kubernetes/deploy** directory to get the Node.js and Python YAML files. - -1. Import the Node.js application into Meshery. - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-node-application.js" id="embedded-design-13665e6e-53cc-4cf4-9e8e-280237428672" >}} - -The Dapr annotations in the manifest file will let the Dapr sidecar injector know that it is supposed to inject a sidecar container into this pod during creation. - -```yaml -annotations: - dapr.io/enabled: "true" - dapr.io/app-id: "nodeapp" - dapr.io/app-port: "3000" - dapr.io/enable-api-logging: "true" -``` -1. Click the **Actions** button and deploy. - -

Deploy Python Application

- -Follow previous steps to import and Deploy the python application. - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-python-application.js" id="embedded-design-03016ef6-7124-4169-a5c0-f403711d480d" >}} -Switch to visualizer and filter according to these specifications: - -- For **View Selector** select **Single Namespace**. -- For **Kinds** select the resources you want to see including _Deployments, Pods, Services, Replicaset_. -- For **Labels** select _app=node_ and _app=python_. - -You should see the daprd sidecar containers in both the python and node pods. - -{{< image src="/images/learning-path/dapr/filter-node-python.png" width="100%" align="center" alt="" >}} - -{{< /chapterstyle >}} \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-redis.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-redis.md deleted file mode 100644 index 70980ec1a..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/deploy-redis.md +++ /dev/null @@ -1,31 +0,0 @@ ---- -docType: "Chapter" -id: "deploy-redis" -chapterTitle: "Deploy Redis" -description: "This chapter covers the deployment of Redis Statestore" -lectures: 4 -weight: 3 -title: "Deploy Redis" ---- - -{{< chapterstyle >}} - -

Import Redis Helm Chart and Deploy to Cluster

- -1. Follow the same steps used for the Dapr deployment to import this [Redis helm chart](https://charts.bitnami.com/bitnami/redis-19.6.2.tgz) into Meshery and deploy. - -{{< meshery-design-embed src="/images/learning-path/embed-test/embedded-design-redis.js" id="embedded-design-c3dcee44-6b8a-498f-a44c-66682ccf4d2a" >}} - -2. Click **Actions** to deploy, then click **Open In Visualizer**. -3. In **Visualizer** mode, use the filter to adjust the views of the resources in the cluster. - - For **View Selector** select **Single Node**. - - For **Kinds** select the resources you want to see including _Deployments,Pods, Services, Statefulset, Secret, Replicaset, Endpoints and Endpoint slices_. - - For **Namespaces** select _dapr_system_ and _default_. - -These filter settings will allow you to view both Dapr resources within the _dapr-system_ namespace and Redis resources within the default namespace. - -{{< image src="/images/learning-path/dapr/redis-dapr.png" width="100%" align="center" alt="" >}} - -Next, let's deploy the Dapr state store component that will manage this Redis state store. - -{{< /chapterstyle >}} diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/introduction.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/introduction.md deleted file mode 100644 index c0d291f22..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/introduction.md +++ /dev/null @@ -1,53 +0,0 @@ ---- -docType: "Chapter" -id: "introduction" -chapterTitle: "Understanding How Dapr Works in a Kubernetes Cluster: A Visual Guide with Meshery" -description: "Learn how Dapr works by deploying Dapr and sample applications in a Kubernetes Cluster using Meshery." -lectures: 4 -title: "Introduction" -weight: 1 ---- - -{{< chapterstyle >}} - -

Introduction

- -In this tutorial, you will explore how [Dapr](https://dapr.io/)(Distributed Application Runtime) operates within a Kubernetes cluster. - -Using Meshery you will deploy the Dapr Helm chart along with sample applications: a Python application that generates messages and a Node.js application that consumes and stores those messages in a Redis state store, managed through Dapr's state store component model. - -Meshery's Kanvas visualization capabilities allow you to examine the components involved in this architecture and understand their relationships. This breakdown helps you see how Dapr interacts with the applications, enhancing your comprehension of its functionality. - -This tutorial expands on the [Hello Kubernetes tutorial with Dapr](https://github.com/dapr/quickstarts/tree/master/tutorials/hello-kubernetes), providing a visual approach to learning Dapr in a Kubernetes environment. - - -

Dapr Architecture

- -In a Dapr-enabled application, the sidecar architecture is central to how Dapr provides its functionalities. Each application pod in your Kubernetes cluster gets a Dapr sidecar injected, which acts as a proxy and mediator for service-to-service calls, state management, and other capabilities. This architecture allows Dapr to offer a set of APIs that simplify common microservice tasks such as **service invocation**, **state management**, and **pub/sub messaging**. - -When one service needs to call another, the request is made to the local Dapr sidecar, which routes the request to the appropriate sidecar in the target service's pod. The target sidecar then forwards the request to its application. - -Similarly, when your application makes a state management request (e.g., saving or retrieving state), it communicates with its local Dapr sidecar. The sidecar then uses the configuration retrieved from the Dapr control plane to interact with the configured state store. - -This architecture ensures that your application remains loosely coupled and can leverage Dapr's capabilities without being tightly integrated with the infrastructure details. - -The diagram below illustrates this setup, providing a visual representation of how Dapr components interact within the architecture. We will explore more on these concepts in subsequent chapters. - -{{< image src="/images/learning-path/dapr/architecture.png" width="100%" align="center" alt="" >}} - -**Prerequisite** - -1. Access to Meshery ([Self-Hosted](https://docs.meshery.io/installation) or [Meshery Playground](https://docs.meshery.io/installation/playground)). -1. Kubernetes Cluster connected to Meshery. - - -{{< alert title="Available Clusters" >}} If you are using a self-hosted Meshery deployment, connect to your Kubernetes cluster using this [Guide](https://docs.meshery.io/installation/kubernetes). Alternatively, Meshery Playground users can use the live pre-registered Kubernetes connection. This tutorial uses a self-hosted Meshery deployment with a connected **Minikube** cluster. -{{< /alert >}} - -

Learning Objectives

- -1. Gain hands-on experience in deploying Dapr on a Kubernetes cluster using Meshery. -1. Learn how to visualize these components using Meshery and get a better understanding of the Dapr architecture and interactions. -1. Understand how to use Dapr's state management capabilities to persist data in a Redis state store, and see how the Node.js app interacts with the state store to save and retrieve data. - -{{< /chapterstyle >}} \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/view-application-logs.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/view-application-logs.md deleted file mode 100644 index 79fa8ae5e..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/explore-dapr-with-meshery/dapr/view-application-logs.md +++ /dev/null @@ -1,69 +0,0 @@ ---- -docType: "Chapter" -id: "view-application-logs" -chapterTitle: "View Application Logs" -description: "Use Meshery's interactive terminal to view logs of applications" -lectures: 4 -weight: 6 -title: "View Application Logs" ---- - -{{< chapterstyle >}} -In this chapter, we will explore how Dapr utilizes its [API constructs](https://docs.dapr.io/concepts/building-blocks-concept/) to facilitate communication and manage the state of application data within this architecture by observing the container logs. - -

Python Application Logs

- -The Python application code above generates messages that contain data with an **orderId** that increments once per second. - -Here's a snippet from the Python script in **app.js**: - -```python -dapr_port = os.getenv("DAPR_HTTP_PORT", 3500) -dapr_url = "http://localhost:{}/neworder".format(dapr_port) - -n = 0 -while True: - n += 1 - message = {"data": {"orderId": n}} - - try: - response = requests.post(dapr_url, json=message) - except Exception as e: - print(e) - - time.sleep(1) -``` -The Dapr sidecar for the Python application sends a POST request to the Dapr sidecar of the Node.js application using the **Dapr service invocation API**. Here's a breakdown of what happens; - -1. The Python app sends a POST request to its sidecar at http://localhost:3500/v1.0/invoke/nodeapp/method/neworder. _Note: http://localhost:3500 is the default listening port for Dapr_. - -1. The sidecar for the Python app invokes the nodeapp service through its own Dapr sidecar. - -The Python app does not need to know the exact address or port of the Node.js service, it simply makes a request to its sidecar, which handles the routing. - - -**Steps to Stream Python Application Logs**: - -1. Click on the **python-app** pod. -1. On the right sidebar, click on **Action**. -1. Click on **Stream Container logs**. - - -{{< image src="/images/learning-path/dapr/stream.png" width="100%" align="center" alt="" >}} - -The logs show the daprd container logs with a POST request made to **/neworder** endpoint. - - -

Node.js Application Logs

- -Follow the same steps above to get the logs for the Node.js application. The logs show API calls made to the state store for persisting order data. - -Here's what can be observed from the logs: - -1. The Dapr sidecar of the Node.js application listens on port 3500 for incoming HTTP requests. -1. The sidecar receives the invocation request sent from the sidecar of the Python app and routes it to the **/neworder** endpoint in the Node.js application. -1. The sidecar makes a POST request to the state store endpoint (/v1.0/state/statestore) to persist the state information in Redis. This endpoint is part of the **Dapr state management API** and is mapped to the configured state store component. - -By analyzing these logs, we gained a deeper understanding of how Dapr's APIs such as the state management API and service invocation API work together to enable service-service communication and efficient management of application state. - -{{< /chapterstyle >}} \ No newline at end of file diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/scalable-postgres-with-cloudnativepg/_index.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/scalable-postgres-with-cloudnativepg/_index.md deleted file mode 100644 index c11667022..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/scalable-postgres-with-cloudnativepg/_index.md +++ /dev/null @@ -1,27 +0,0 @@ ---- -docType: "Course" -title: "Scalable Postgres with CloudNativePG" -description: "Learn how to Install a Scalable PostgreSQL Distribution on Kubernetes with Cloud Native PostgreSQL" -lectures: 7 -courseTitle: "Scalable Postgres with CloudNativePG" -themeColor: "#00B39F" -order: 1 -cardImage: "../../../src/images/service-mesh-icons/linkerd-white.svg" -meshesYouLearn: - [ - { - imagepath: "../../../src/images/service-mesh-icons/istio.svg", - name: "Istio" - }, - { - imagepath: "../../../src/images/service-mesh-icons/linkerd.svg", - name: "Linkerd" - } - ] -toc: - [ - "introduction" - ] ---- - -A course that will help you to install a Scalable PostgreSQL Distribution on Kubernetes with Cloud Native PostgreSQL diff --git a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/scalable-postgres-with-cloudnativepg/postgres/introduction.md b/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/scalable-postgres-with-cloudnativepg/postgres/introduction.md deleted file mode 100644 index b0bf7a3c9..000000000 --- a/content/challenges/11111111-1111-1111-1111-111111111111/mastering-kubernetes-for-engineers/scalable-postgres-with-cloudnativepg/postgres/introduction.md +++ /dev/null @@ -1,46 +0,0 @@ ---- -docType: "Chapter" -id: "introduction" -chapterTitle: "Introduction" -description: "" -lectures: 12 -title: "Introduction" -weight: 1 ---- - -{{< chapterstyle >}} - -In this tutorial, you will learn how to **Install a Scalable PostgreSQL Distribution on Kubernetes with Cloud Native PostgreSQL** using Meshery Playground. Meshery Playground is an interactive and collaborative live cluster environment that simplifies the deployment process and enhances user experience by providing visual tools for managing Kubernetes resources. - -> **NOTE:** If this is your first time working with Meshery Playground, consider starting with the [Exploring Kubernetes Pods with Meshery Playground](https://docs.meshery.io/guides/tutorials/kubernetes-pods) tutorial first. - -

Prerequisites

- -- Basic understanding of Kubernetes concepts. -- Access to the _Meshery Playground_. If you don't have an account, sign up at [Meshery Playground](https://play.meshery.io/). - -

Lab Scenario

- -- Import the CloudnativePG manifest files -- Import manifest files for sample application -- Deploy these resources on the playground - - -

Objective

- -Learn how to deploy and manage postgreSQL and a Python sample application using CloudNative PG and Meshery Playground. This tutorial will demonstrate how to import manifest files, visualize kubernetes resources, and observe the dynamic provisioning capabilities of CloudNativePG. By the end of this tutorial, you will have a clear understanding of how to leverage Meshery Playground for deployments and visualization. - -

CloudNativePG

- -CloudNative PG is a level 5 Kubernetes operator that efficiently manages PostgreSQL clusters, ensuring high availability throughout their lifecycle. It offers seamless Kubernetes API integration, declarative configuration, -advanced observability, and is secure by default. -CloudNative PG encapsulates PostgreSQL within a Kubernetes-native framework, adhering to cloud-native principles for deployment, -scaling, and management. It uses CRDs and Operator patterns for seamless integration with Kubernetes, enabling automated provisioning, scaling, and management of PostgreSQL clusters. - - -

Access Meshery Playground

- -1. Log in to the [Meshery Playground](https://cloud.layer5.io/) using your credentials. On successful login, you should be at the dashboard. Press the **X** on the _Where do you want to start?_ popup to close it (if required). -2. Click **Explore** in the Cloud Native Playground tile to navigate to _Kanvas_ - -{{< /chapterstyle >}} \ No newline at end of file diff --git a/content/challenges/_index.md b/content/challenges/_index.md index 9bc3d5968..1f3d6d1e5 100644 --- a/content/challenges/_index.md +++ b/content/challenges/_index.md @@ -1,7 +1,7 @@ --- -title: Learning Paths -description: Learn about the various learning paths available in the Layer5 ecosystem. -linkTitle: Learning Paths +title: Challenges +description: "Explore the challenges in Layer5 Academy. Each challenge is designed to help you learn and practice your skills in a hands-on way." +linkTitle: Challenges # tells hugo that this section is of type learning-path ( to use appropiate templates ) type: learning-paths cascade: # tells hugo to set this as default type for all children content in this section @@ -10,6 +10,6 @@ cascade: # tells hugo to set this as default type for all children content in th {{% pageinfo %}} -### Learning Paths +### Challenges {{% /pageinfo %}} diff --git a/static/11111111-1111-1111-1111-111111111111/images/jaeger-icon-black.svg b/static/11111111-1111-1111-1111-111111111111/images/jaeger-icon-black.svg new file mode 100644 index 000000000..130d3b9ae --- /dev/null +++ b/static/11111111-1111-1111-1111-111111111111/images/jaeger-icon-black.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/static/11111111-1111-1111-1111-111111111111/images/keda-icon.svg b/static/11111111-1111-1111-1111-111111111111/images/keda-icon.svg new file mode 100644 index 000000000..a36aa2754 --- /dev/null +++ b/static/11111111-1111-1111-1111-111111111111/images/keda-icon.svg @@ -0,0 +1 @@ +keda-icon