
Now, build and deploy the application from the following. Your cluster probably doesn't know about it yet, so import the version into your namespace using the -f option in the following command (for more information, see Installing.


You'll need this information later to configure the debugger.įor the S2I build, we'll use the latest. When you build the application, note the path where the source code resides. Also, make sure your image contains the ps utility, which the Kubernetes plugin uses to find the. Be sure to build the application in the Debug configuration. NET application and deploy it on the cluster. If you are not using OpenShift, you should build a container image from a. In this section, you'll use the OpenShift Source-to-Image (S2I) strategy to build and deploy an image on your cluster. $ kubectl config use-context default/$NAME/kubeuser Deploy your application $ kubectl config set-context default/$NAME/kubeuser -user=kubeuser/$NAME -namespace=$NAMESPACE -cluster=$NAME $ kubectl config set-cluster $NAME -server=$URL If you have installed the oc client, you can connect to your OpenShift cluster using the login command, then select the namespace using the project command: $ oc login -token=$TOKEN -server=$URLĪlternatively, using kubectl, you can log in as follows: $ kubectl config set-credentials kubeuser/$NAME -token=$TOKEN The commands in this section indicate where you should enter the following: Next, you will connect to the cluster and select its namespace.

If you haven't already installed Visual Studio Code, do so using the instructions at the VS Code website.Īs your final step in setting up the environment, start the IDE and install the C# extension and Kubernetes extension. If you are using OpenShift, also install the OpenShift oc CLI: $ sudo dnf install origin-clients On Fedora, you can install kubectl with the following command: $ sudo dnf install kubernetes-client Install the Kubernetes command-line interface (CLI), kubectl, which VS Code uses to interact with Kubernetes. With a few plugins and configurations, VS Code can work very smoothly in these cloud environments. Programmers generally run VS Code on their local systems, but in the cloud era, you'll sometimes want to debug applications in the Kubernetes or Red Hat OpenShift environment where you're deploying them. Visual Studio Code (VS Code) is the integrated development environment (IDE) used by most.
