API
The Gcore Customer Portal is being updated. Screenshots may not show the current version.
Edge Cloud
Edge Cloud
OverviewBillingTerraform
API
Chosen image
Home/Edge Cloud/Managed Kubernetes/Networking/Use nginx Controller

Use nginx Ingress Controller

To start using the controller, you need to apply an Ingress manifest.

1. Create a YAML file to create an Ingress object:

apiVersion: extensions/v1beta1 kind: Ingress metadata: name: hello-world-ingress spec: ingressClassName: nginx rules: - http: paths: - path: / backend: serviceName: hello-world-svc servicePort: 80

Enter your custom values instead:

  • hello-world-ingress: Name of the Ingress object
  • nginx: Name of ingressClassResource
  • /: Default URL path
  • hello-world-svc: Name of the Service that will manage the requests
  • 80: Port of the Service that will manage the requests

2. Run the kubectl command.

kubectl apply -f <name of the created YAML-file>

You’ll get the output:

Ingress/<name of the created ingress object> created

This means you’ve successfully created and applied an Ingress object for the nginx Ingress Controller.

Was this article helpful?

Not a Gcore user yet?

Discover our offerings, including virtual instances starting from 3.7 euro/mo, bare metal servers, AI Infrastructure, load balancers, Managed Kubernetes, Function as a Service, and Centralized Logging solutions.

Go to the product page
// // Initialize a variable to undefined initially. // var growthBook = undefined; // (function() { // try { // var script = document.createElement('script'); // script.src = "https://cdn.jsdelivr.net/npm/@growthbook/growthbook/dist/bundles/auto.min.js"; // script.setAttribute("data-api-host", "https://cdn.growthbook.io"); // script.setAttribute("data-client-key", "sdk-truekA5wvhMYaqsu"); // document.head.appendChild(script); // script.onload = function() { // console.log("GrowthBook script loaded successfully."); // growthBook = window.GrowthBook; // Assuming GrowthBook attaches itself to window // }; // script.onerror = function() { // console.error("Failed to load the GrowthBook script."); // growthBook = undefined; // Explicitly set to undefined on error // }; // } catch (error) { // console.error("An error occurred while setting up the GrowthBook script:", error); // growthBook = undefined; // } // })(); // // Optional: Push to dataLayer if needed // window.dataLayer = window.dataLayer || []; // window.dataLayer.push({ // 'event': 'scriptLoadStatus', // 'growthBookStatus': growthBook ? "Loaded" : "Failed" // });