Skip to content

Commit f0e70a0

Browse files
authored
Merge pull request #296319 from MitchellGale/service-principal
Data Factory - Azure Database for PostgreSQL connector - Adding Service principal
2 parents 013bb9c + 26e285d commit f0e70a0

File tree

2 files changed

+81
-2
lines changed

2 files changed

+81
-2
lines changed

articles/data-factory/connector-azure-database-for-postgresql.md

Lines changed: 81 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,11 +83,10 @@ The following properties are supported for the Azure Database for PostgreSQL lin
8383
|:--- |:--- |:--- |
8484
| type | The type property must be set to: **AzurePostgreSql**. | Yes |
8585
| version | The version that you specify. The value is `2.0`. | Yes |
86+
| authenticationType | Select from basic or service principal authentication | Yes |
8687
| server | Specifies the host name and optionally port on which Azure Database for PostgreSQL is running. | Yes |
8788
| port |The TCP port of the Azure Database for PostgreSQL server. The default value is `5432`. |No |
8889
| database| The name of the Azure Database for PostgreSQL database to connect to. |Yes |
89-
| username| The username to connect with. Not required if using IntegratedSecurity. |Yes |
90-
| password| The password to connect with. Not required if using IntegratedSecurity. Mark this field as **SecureString** to store it securely. Or, you can [reference a secret stored in Azure Key Vault](store-credentials-in-key-vault.md). |Yes |
9190
| sslMode | Controls whether SSL is used, depending on server support. <br/>- **Disable**: SSL is disabled. If the server requires SSL, the connection will fail.<br/>- **Allow**: Prefer non-SSL connections if the server allows them, but allow SSL connections.<br/>- **Prefer**: Prefer SSL connections if the server allows them, but allow connections without SSL.<br/>- **Require**: The connection fails if the server doesn't support SSL.<br/>- **Verify-ca**: The connection fails if the server doesn't support SSL. Also verifies server certificate.<br/>- **Verify-full**: The connection fails if the server doesn't support SSL. Also verifies server certificate with host's name. <br/>Options: Disable (0) / Allow (1) / Prefer (2) **(Default)** / Require (3) / Verify-ca (4) / Verify-full (5) | No |
9291
| connectVia | This property represents the [integration runtime](concepts-integration-runtime.md) to be used to connect to the data store. You can use Azure Integration Runtime or Self-hosted Integration Runtime (if your data store is located in private network). If not specified, it uses the default Azure Integration Runtime.|No|
9392
| ***Additional connection properties:*** | | |
@@ -100,6 +99,13 @@ The following properties are supported for the Azure Database for PostgreSQL lin
10099
| timezone | Gets or sets the session timezone. | No |
101100
| encoding | Gets or sets the .NET encoding that will be used to encode/decode PostgreSQL string data. | No |
102101

102+
### Basic authentication
103+
104+
| Property | Description | Required |
105+
|:--- |:--- |:--- |
106+
| username | The username to connect with. Not required if using IntegratedSecurity. | Yes |
107+
| password | The password to connect with. Not required if using IntegratedSecurity. Mark this field as **SecureString** to store it securely. Or, you can [reference a secret stored in Azure Key Vault](store-credentials-in-key-vault.md). | Yes |
108+
103109
**Example**:
104110

105111
```json
@@ -149,8 +155,81 @@ The following properties are supported for the Azure Database for PostgreSQL lin
149155
}
150156
}
151157
}
158+
```
159+
160+
### Service principal authentication
161+
162+
| Property | Description | Required |
163+
|:--- |:--- |:--- |
164+
| username | The display name of the service principal | Yes |
165+
| tenant | The tenant which the Azure Database for PostgreSQL server is located |Yes |
166+
| servicePrincipalId | Application ID of service principal |Yes |
167+
| servicePrincipalCredentialType | Select if service principal certificate or service principal key is desired authentication method<br/>- **ServicePrincipalCert**: Set to service principal certificate for service principal certificate.<br/>- **ServicePrincipalKey**: Set to service principal key for service principal key authentication. | Yes |
168+
| servicePrincipalKey | Client secret value. Used when service principal key is selected | Yes |
169+
| azureCloudType | Select the Azure cloud type of your Azure Database for PostgreSQL server | Yes |
170+
| servicePrincipalEmbeddedCert | Service principal certificate file | Yes |
171+
| servicePrincipalEmbeddedCertPassword | Service principal certificate password if required | No |
172+
173+
**Example**:
174+
175+
**Service principal key**
176+
```json
177+
{
178+
"name": "AzurePostgreSqlLinkedService",
179+
"type": "Microsoft.DataFactory/factories/linkedservices",
180+
"properties": {
181+
"annotations": [],
182+
"type": "AzurePostgreSql",
183+
"version": "2.0",
184+
"typeProperties": {
185+
"server": "<server name>",
186+
"port": 5432,
187+
"database": "<database name>",
188+
"sslMode": 2,
189+
"username": "<service principal name>",
190+
"authenticationType": "<authentication type>",
191+
"tenant": "<tenant>",
192+
"servicePrincipalId": "<service principal ID>",
193+
"azureCloudType": "<azure cloud type>",
194+
"servicePrincipalCredentialType": "<service principal type>",
195+
"servicePrincipalKey": "<service principal key>"
196+
}
197+
}
198+
}
199+
```
200+
201+
**Example**:
202+
203+
**Service principal certificate**
204+
```json
205+
{
206+
"name": "AzurePostgreSqlLinkedService",
207+
"type": "Microsoft.DataFactory/factories/linkedservices",
208+
"properties": {
209+
"annotations": [],
210+
"type": "AzurePostgreSql",
211+
"version": "2.0",
212+
"typeProperties": {
213+
"server": "<server name>",
214+
"port": 5432,
215+
"database": "<database name>",
216+
"sslMode": 2,
217+
"username": "<service principal name>",
218+
"authenticationType": "<authentication type>",
219+
"tenant": "<tenant>",
220+
"servicePrincipalId": "<service principal ID>",
221+
"azureCloudType": "<azure cloud type>",
222+
"servicePrincipalCredentialType": "<service principal type>",
223+
"servicePrincipalEmbeddedCert": "<service principal certificate>",
224+
"servicePrincipalEmbeddedCertPassword": "<service principal embedded certificate password>"
225+
}
226+
}
227+
}
152228
```
153229

230+
231+
232+
154233
### Version 1.0
155234

156235
The following properties are supported for the Azure Database for PostgreSQL linked service when you apply version 1.0:
Loading

0 commit comments

Comments
 (0)