You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: bridge/articles/bridge-to-kubernetes-aks.md
+15-17Lines changed: 15 additions & 17 deletions
Original file line number
Diff line number
Diff line change
@@ -12,7 +12,7 @@ description: Learn how to use Bridge to Kubernetes to connect your development c
12
12
13
13
# Use Bridge to Kubernetes with AKS
14
14
15
-
In this tutorial, you'll use a specific AKS sample microservices web app to learn how to use Bridge to Kubernetes to debug locally in a single pod that's part of an Azure Kubernetes Service (AKS) cluster.
15
+
In this tutorial, you use a specific AKS sample microservices web app to learn how to use Bridge to Kubernetes to debug locally in a single pod that's part of an Azure Kubernetes Service (AKS) cluster.
16
16
17
17
## Before you begin
18
18
@@ -27,7 +27,7 @@ This guide uses the [Todo App sample application](https://github.com/Azure/Bridg
27
27
28
28
## Create a Kubernetes cluster
29
29
30
-
Create an AKS cluster in a [supported region][supported-regions]. The below commands create a resource group called `MyResourceGroup` and an AKS cluster called `MyAKS`.
30
+
Create an AKS cluster in a [supported region][supported-regions]. The following commands create a resource group called `MyResourceGroup` and an AKS cluster called `MyAKS`.
On your development computer, download and configure the Kubernetes CLI to connect to your Kubernetes cluster using [az aks get-credentials][az-aks-get-credentials].
56
+
On your development computer, download and configure the Kubernetes CLI to connect to your Kubernetes cluster using [`az aks get-credentials`][az-aks-get-credentials].
57
57
58
58
```azurecli
59
59
az aks get-credentials --resource-group MyResourceGroup --name MyAKS
On the same terminal you were using earlier run below command and copy the IP for front end service under the External IP columnd.
67
+
On the same terminal you were using earlier, run the following command and copy the IP for front end service under the External IP column.
68
68
69
69
```azurecli
70
70
kubectl get services
71
71
```
72
72
73
73
To try out the app, open the url:
74
-
(your external IP from above command goes here).nip.io
74
+
`{your external IP from above command goes here}.nip.io`
75
75
76
76
## Debug stats-api service
77
77
78
-
On the same terminal you were using earlier type below ot open stats-api in vscode.
78
+
On the same terminal you were using earlier, type the following command to open stats-api in VS Code.
79
79
80
80
```azurecli
81
81
code ./stats-api
@@ -91,7 +91,7 @@ Next, configure bridge: open the Command Palette (**CTRL**+**SHIFT**+**P** or **
91
91
92
92

93
93
94
-
You are prompted to configure the service you want to replace, the port to forward from your development computer, and the launch task to use.
94
+
You're prompted to configure the service you want to replace, the port to forward from your development computer, and the launch task to use.
95
95
96
96
Choose the `stats-api` service.
97
97
@@ -100,15 +100,15 @@ Choose the `stats-api` service.
100
100
> [!IMPORTANT]
101
101
> You can only redirect services that have a single pod.
102
102
103
-
After you select your service, you are prompted to enter the TCP port for your local application. For this example, enter 3001.
103
+
After you select your service, you're prompted to enter the TCP port for your local application. For this example, enter 3001.
104
104
105
105

106
106
107
107
Choose **Run Script: dev** as the launch task.
108
108
109
109

110
110
111
-
You have the option of running isolated or not isolated. If you run isolated, only your requests are routed to your local process; other developers can use the cluster without being affected. If you don't run isolated, all traffic is redirected to your local process. For more information on this option, see [Using routing capabilities for developing in isolation](overview-bridge-to-kubernetes.md#using-routing-capabilities-for-developing-in-isolation). For this example, we will proceed with non-isolated. If you chose isolation, task.json will have the prefix you should use to route request to your machine.
111
+
You have the option of running isolated or not isolated. If you run isolated, only your requests are routed to your local process; other developers can use the cluster without being affected. If you don't run isolated, all traffic is redirected to your local process. For more information on this option, see [Using routing capabilities for developing in isolation](overview-bridge-to-kubernetes.md#using-routing-capabilities-for-developing-in-isolation). For this example, we proceed with non-isolated. If you chose isolation, task.json has the prefix you should use to route request to your machine.
112
112
113
113

114
114
@@ -124,11 +124,11 @@ To start debugging, select the Debug icon on the left and select **Run Script: d
124
124
> [!NOTE]
125
125
> You will be prompted to allow the EndpointManager to run elevated and modify your hosts file.
126
126
127
-
Your development computer is connected when the VS Code status bar turns orange and the Kubernetes extension shows you are connected. Once your development computer is connected, traffic starts redirecting to your development computer for the stats-api you are replacing.
127
+
Your development computer is connected when the VS Code status bar turns orange and the Kubernetes extension shows you're connected. Once your development computer is connected, traffic starts redirecting to your development computer for the stats-api you're replacing.
128
128
129
129

130
130
131
-
Navigate to the frontend entry point of your todo-app. Using that external IP you found earlier (your external IP from get services command).nip.io. Note, if you selected isolation mode, you will need to use (your prefix - can be found in task.json).(your external IP from get services command).nip.io.
131
+
Navigate to the frontend entry point of your todo-app. Using that external IP you found earlier `{your external IP from get services command}.nip.io`. Note, if you selected isolation mode, you need to use `{your prefix - can be found in task.json}.{your external IP from get services command}.nip.io`.
132
132
133
133
Make a request to the stats-api by choosing the **stats** link.
134
134
@@ -140,9 +140,9 @@ Press play and let the request continue complete transparently.
140
140
141
141
## Clean up
142
142
143
-
When you stop the debugger all changes to the cluster are reverted. Note, if you were running with isolation on, the routing manager pod will be left there to expedite the start of the debugger the next time around.
143
+
When you stop the debugger, all changes to the cluster are reverted. Note, if you were running with isolation on, the routing manager pod will be left there to expedite the start of the debugger the next time around.
144
144
145
-
You can leave your AKS cluster on for future debugging or you can delete it with below command.
145
+
You can leave your AKS cluster on for future debugging or you can delete it with following command.
146
146
147
147
```azurecli-interactive
148
148
az aks delete --name MyAKS --resource-group MyResourceGroup
@@ -160,9 +160,7 @@ Learn more about Bridge to Kubernetes at [How Bridge to Kubernetes works][btk-ho
Copy file name to clipboardExpand all lines: bridge/articles/bridge-to-kubernetes-vs-code.md
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ manager: jmartens
6
6
ms.technology: bridge
7
7
ms.custom: "contperf-fy22q1"
8
8
title: Use Bridge to Kubernetes to run and debug locally with Kubernetes (VS Code)
9
-
ms.date: 08/11/2022
9
+
ms.date: 09/14/2023
10
10
description: Learn how to use Bridge to Kubernetes to connect your development computer to a Kubernetes cluster and use local tunnel debugging to debug Kubernetes services on your local machine.
11
11
---
12
12
@@ -146,7 +146,7 @@ var response = await client.SendAsync(request);
146
146
> [!NOTE]
147
147
> To avoid affecting code at every request, you can create a class that inherits from [System.Net.Http.DelegatingHandler](/dotnet/api/system.net.http.delegatinghandler) and override the `SendAsync` method with code similar to the preceding example. You can find code using this technique on the web; one example is [Properly Propagating "kubernetes-route-as" in Bridge to Kubernetes](https://blogs.u2u.be/lander/post/2020/11/25/properly-propagating-kubernetes-route-as-in-bridge-to-kubernetes).
148
148
149
-
For Node.js services, you can use code similar to the following, taken from the todo-app sample in the [mindaro repo](https://github.com/Microsoft/mindaro):
149
+
For Node.js services, you can use code similar to the following, taken from the todo-app sample in the [Bridge to Kubernetes repo](https://github.com/Azure/Bridge-To-Kubernetes):
Copy file name to clipboardExpand all lines: docs/azure/overview-azure-integration.md
+3-3Lines changed: 3 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
---
2
-
title: Azure development with Visual Studio
3
-
description: Learn about how you can connect your apps to Azure services in Visual Studio and deploy them to the cloud.
2
+
title: Work with Azure with Visual Studio
3
+
description: Learn about how you can provision Azure resources, browse existing Azure resources, and deploy applications to Azure services with Visual Studio.
Copy file name to clipboardExpand all lines: docs/azure/overview-connected-services.md
+25-25Lines changed: 25 additions & 25 deletions
Original file line number
Diff line number
Diff line change
@@ -34,6 +34,7 @@ Get started by right-clicking on the project node, and choosing **Add > Connecte
34
34
Supported project types vary by the type of service. You'll see the options that apply to your project type in the listed selections.
35
35
36
36
<aname="azure"/>
37
+
37
38
## Connect your app to Azure services
38
39
39
40
Use Connected Services to connect your application to live Azure services emulators and other local alternatives to Azure services. Visual Studio currently supports the following:
@@ -55,20 +56,21 @@ Use Connected Services to connect your application to live Azure services emulat
55
56
> [!NOTE]
56
57
> Using Publish you can deploy your application to Azure hosting services like Azure VMs, Azure App Service, Azure Functions and Azure Container Registry
57
58
58
-
### Support for Azure emulators and local alternatives
59
-
60
-
Visual Studio makes it easier to develop Azure applications locally by easing the transition from locally emulated services to services running in the cloud. You can use Connected Services to connect your application to local emulators, some of which run in a local container, and other local alternatives to Azure services. Visual Studio currently supports the following:
59
+
## Databases and data providers
61
60
61
+
Visual Studio provides options to connect to on-premises databases, locally emulated versions of data providers, as well as Azure database services.
62
62
63
-
## Connect your app to gRPC, OpenAPI and WCF endpoints
63
+
| Name | Description |
64
+
| - | - |
65
+
|[Azure Cosmos DB Emulator on container](/azure/cosmos-db/introduction)| Azure Cosmos DB emulator running in a local container. |
66
+
|[MongoDB on container](/azure/cosmos-db/introduction)| MongoDB document databases provides high reliability and easy scalability. This option makes it available in a local container. |
67
+
|[PostgreSQL on container](/azure/postgresql/overview)| PostgreSQL is an object-relational database system that provides reliability and data integrity. This option makes it available in a local container. |
68
+
|[SQLite](/ef/core/providers/sqlite/?tabs=dotnet-core-cli)| SQLite is an in-process library that provides a self-contained, transactional SQL database engine with no configuration. |
69
+
|[SQL Server Database](/sql/sql-server/)| On-premises SQL Server Database. |
64
70
65
-
Use Connected Services to connect your application to any of the following services:
71
+
## Support for Azure emulators and local alternatives
66
72
67
-
| Name | ASP.NET Link | Description |
68
-
|-|-|-|
69
-
|[OpenAPI](https://github.com/OAI/OpenAPI-Specification) endpoints |[Develop ASP.NET Core apps with OpenAPI](/aspnet/core/web-api/Microsoft.dotnet-openapi)| A standard format for describing the capabilities of a service in computer-readable and human-readable form. |
70
-
|[gRPC](https://grpc.io/docs/) endpoints |[Introduction to gRPC services on .NET](/aspnet/core/grpc/)| An open-source real-time procedure calling service. |
71
-
|[WCF](/dotnet/framework/wcf/) endpoints | n/a | A .NET Framework solution supporting programming with a distributed network of services. |
73
+
Visual Studio makes it easier to develop Azure applications locally by easing the transition from locally emulated services to services running in the cloud. You can use Connected Services to connect your application to local emulators, some of which run in a local container, and other local alternatives to Azure services. Visual Studio currently supports the following:
72
74
73
75
Visual Studio generates any necessary client or server code to facilitate the communication.
74
76
@@ -82,23 +84,15 @@ Visual Studio generates any necessary client or server code to facilitate the co
82
84
|[Secrets.json](/aspnet/core/security/app-secrets?tabs=windows)| Local alternative for Key Vault. |
83
85
|[SQL Server Express LocalDB](/sql/database-engine/configure-windows/sql-server-express-localdb)| Local alternative to Azure SQL Database. |
84
86
85
-
## Databases and data providers
86
-
87
-
Visual Studio provides options to connect to on-premises databases, locally emulated versions of data providers, as well as Azure database services.
88
-
89
-
| Name | Description |
90
-
| - | - |
91
-
|[Azure Cosmos DB Emulator on container](/azure/cosmos-db/introduction)| Azure Cosmos DB emulator running in a local container. |
92
-
|[MongoDB on container](/azure/cosmos-db/introduction)| MongoDB document databases provides high reliability and easy scalability. This option makes it available in a local container. |
93
-
|[PostgreSQL on container](/azure/postgresql/overview)| PostgreSQL is an object-relational database system that provides reliability and data integrity. This option makes it available in a local container. |
94
-
|[SQLite](/ef/core/providers/sqlite/?tabs=dotnet-core-cli)| SQLite is an in-process library that provides a self-contained, transactional SQL database engine with no configuration. |
95
-
|[SQL Server Database](/sql/sql-server/)| On-premises SQL Server Database. |
96
-
97
-
## How it works
87
+
## Connect your app to gRPC, OpenAPI and WCF endpoints
98
88
99
-
Visual Studio creates two new files visible in Solution Explorer under Properties called *serviceDependencies.json* and *serviceDependencies.local.json*. Both of these files are safe to check in as they do not contain any secrets.
89
+
Use Connected Services to connect your application to any of the following services:
100
90
101
-
Visual Studio also creates a file called *serviceDependencies.local.json.user* which is not visible in Solution Explorer by default. This file contains information that could be considered a secret (for example, resource IDs in Azure) and we do not recommend you check it in.
91
+
| Name | ASP.NET Link | Description |
92
+
|-|-|-|
93
+
|[OpenAPI](https://github.com/OAI/OpenAPI-Specification) endpoints |[Develop ASP.NET Core apps with OpenAPI](/aspnet/core/web-api/Microsoft.dotnet-openapi)| A standard format for describing the capabilities of a service in computer-readable and human-readable form. |
94
+
|[gRPC](https://grpc.io/docs/) endpoints |[Introduction to gRPC services on .NET](/aspnet/core/grpc/)| An open-source real-time procedure calling service. |
95
+
|[WCF](/dotnet/framework/wcf/) endpoints | n/a | A .NET Framework solution supporting programming with a distributed network of services. |
102
96
103
97
## Containers
104
98
@@ -113,3 +107,9 @@ During development, you usually use a local emulator, a local database, or a moc
113
107
If you click those links, Visual Studio will present a few screens that ask for the connection information to the "real" service running in the cloud that your cloud app will use instead of the local service. For example, if you initially configured an app to run with a locally running instance of SQL LocalDB, you would have provided a connection string name and an initial value that referenced that LocalDB database. After your app is first deployed to a cloud environment, you can use the **Configure** links to specify the connection string to use in the cloud. For Azure deployment scenarios, Visual Studio also gives the option of using an [Azure Key Vault](/azure/key-vault/general/overview) to securely store the connection string and other secrets.
114
108
115
109

110
+
111
+
## How it works
112
+
113
+
Visual Studio creates two new files visible in Solution Explorer under Properties called *serviceDependencies.json* and *serviceDependencies.local.json*. Both of these files are safe to check in as they do not contain any secrets.
114
+
115
+
Visual Studio also creates a file called *serviceDependencies.local.json.user* which is not visible in Solution Explorer by default. This file contains information that could be considered a secret (for example, resource IDs in Azure) and we do not recommend you check it in.
0 commit comments