Skip to content

Commit c9a3d22

Browse files
authored
Add us2.ddog-gov.com site (#700)
1 parent e462c84 commit c9a3d22

3 files changed

Lines changed: 3 additions & 2 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ To further configure your plugin, use the following custom parameters in your `s
2727

2828
| Parameter | Description |
2929
| ----------------------------- |------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
30-
| `site` | Set which Datadog site to send data to, such as `datadoghq.com` (default), `datadoghq.eu`, `us3.datadoghq.com`, `us5.datadoghq.com`, `ap1.datadoghq.com`, `ap2.datadoghq.com`, or `ddog-gov.com`. This parameter is required when collecting telemetry using the Datadog Lambda Extension. |
30+
| `site` | Set which Datadog site to send data to, such as `datadoghq.com` (default), `datadoghq.eu`, `us3.datadoghq.com`, `us5.datadoghq.com`, `ap1.datadoghq.com`, `ap2.datadoghq.com`, `ddog-gov.com`, or `us2.ddog-gov.com`. This parameter is required when collecting telemetry using the Datadog Lambda Extension. |
3131
| `apiKey` | [Datadog API key][7]. This parameter is required when collecting telemetry using the Datadog Lambda Extension. Alternatively, you can also set the `DATADOG_API_KEY` environment variable in your deployment environment. |
3232
| `appKey` | Datadog app key. Only needed when the `monitors` field is defined. Alternatively, you can also set the `DATADOG_APP_KEY` environment variable in your deployment environment. |
3333
| `apiKeySecretArn` | An alternative to using the `apiKey` field. The ARN of the secret that is storing the Datadog API key in AWS Secrets Manager. Remember to add the `secretsmanager:GetSecretValue` permission to the Lambda execution role. |

src/index.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -803,7 +803,7 @@ describe("ServerlessPlugin", () => {
803803
}
804804
expect(threwError).toBe(true);
805805
expect(thrownErrorMessage).toEqual(
806-
"Warning: Invalid site URL. Must be one of datadoghq.com, datadoghq.eu, us3.datadoghq.com, us5.datadoghq.com, ap1.datadoghq.com, ap2.datadoghq.com, ddog-gov.com.",
806+
"Warning: Invalid site URL. Must be one of datadoghq.com, datadoghq.eu, us3.datadoghq.com, us5.datadoghq.com, ap1.datadoghq.com, ap2.datadoghq.com, ddog-gov.com, us2.ddog-gov.com.",
807807
);
808808
});
809809

src/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -640,6 +640,7 @@ function validateConfiguration(config: Configuration): void {
640640
"ap1.datadoghq.com",
641641
"ap2.datadoghq.com",
642642
"ddog-gov.com",
643+
"us2.ddog-gov.com",
643644
];
644645
if (!config.testingMode && config.site !== undefined && !siteList.includes(config.site.toLowerCase())) {
645646
throw new Error(`Warning: Invalid site URL. Must be one of ${siteList.join(", ")}.`);

0 commit comments

Comments
 (0)