Skip to content

Commit

Permalink
[Monitor] Add client configuration info to README (Azure#32326)
Browse files Browse the repository at this point in the history
This adds a section to the README about configuring the
LogsIngestionClient for non-public clouds.

Signed-off-by: Paul Van Eck <[email protected]>
  • Loading branch information
pvaneck authored and mccoyp committed Oct 6, 2023
1 parent 51bae16 commit 5156294
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions sdk/monitor/azure-monitor-ingestion/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,14 @@ credential = DefaultAzureCredential()
logs_client = LogsIngestionClient(endpoint, credential)
```

#### Configure clients for non-public Azure clouds

By default, `LogsIngestionClient` is configured to connect to the public Azure cloud. To connect to non-public Azure clouds, some additional configuration is required. The appropriate scope for authentication must be provided using the `credential_scopes` keyword argument. The following example shows how to configure the client to connect to Azure US Government:

```python
logs_client = LogsIngestionClient(endpoint, credential_scopes=["https://monitor.azure.us//.default"])
```

## Key concepts

### Data Collection Endpoint
Expand Down

0 comments on commit 5156294

Please sign in to comment.