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
* Add IaC CI setup doc
* Fix heading capitalization and variable name mismatch in IaC CI setup doc
* Apply word-list and sentence-length fixes to IaC CI setup doc
* Update from feedback on iac-setup
* Update hugo/content/en/security/code_security/iac_security/setup.md
Co-authored-by: May Lee <may.lee@datadoghq.com>
---------
Co-authored-by: May Lee <may.lee@datadoghq.com>
Copy file name to clipboardExpand all lines: hugo/content/en/security/code_security/iac_security/setup.md
+54Lines changed: 54 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -94,6 +94,57 @@ After setting up the Azure DevOps integration, enable IaC Security for your repo
94
94
{{% /tab %}}
95
95
{{< /tabs >}}
96
96
97
+
## Set up IaC with a generic CI provider
98
+
99
+
### Overview
100
+
101
+
If you don't use GitHub Actions, GitLab CI/CD, or Azure DevOps, you can run the [Datadog IaC Scanner][8] directly in your CI pipeline. Upload IaC scan results to Datadog using the [`datadog-ci` CLI][9].
102
+
103
+
**If you are running IaC Security on a non-GitHub repository**, run the first scan on your default branch. If your default branch uses a name other than `master`, `main`, `default`, `stable`, `source`, `prod`, or `develop`, upload a first scan for your repository. Then, manually override the default branch in [{{< ui >}}Repository Settings{{< /ui >}}][10] so that future scans from non-default branches are uploaded and correctly processed.
104
+
105
+
### Prerequisites
106
+
107
+
- Node.js 20 or later and npm
108
+
-`curl`
109
+
-`tar`
110
+
- Permission to install the scanner in `/usr/local/bin`
|`DD_API_KEY`| Your Datadog API key. Create this key in your [Datadog organization][4] and store the key as a secret. | Yes ||
117
+
|`DD_APP_KEY`| Your application key. Create this key in your [Datadog organization][4] and include the `code_analysis_read` scope. Store the key as a secret. | Yes ||
118
+
|`DD_SITE`| The [Datadog site][5] to send information to. Your Datadog site is `datadoghq.com`. | No |`datadoghq.com`|
119
+
120
+
Add the following to your CI pipeline:
121
+
122
+
```bash
123
+
# Set the Datadog site to send information to
124
+
export DD_SITE="datadoghq.com"
125
+
126
+
# Install dependencies
127
+
npm install -g @datadog/datadog-ci
128
+
129
+
# Download the latest Datadog IaC Scanner (x86_64/amd64 Linux; see GitHub Releases for arm64 and other platforms)
This example uses the x86_64 (amd64) Linux version of the Datadog IaC Scanner. The scanner also supports arm64 Linux, as well as macOS and Windows. If you're using a different OS or architecture, select the appropriate release from the <ahref="https://github.com/DataDog/datadog-iac-scanner/releases">GitHub Releases</a> page and update the <code>IAC_SCANNER_URL</code> value.
146
+
</div>
147
+
97
148
## Upload third-party static analysis results to IaC Security
98
149
99
150
<divclass="alert alert-info">
@@ -149,3 +200,6 @@ To ensure proper ingestion and display in Datadog IaC Scanning for third-party s
0 commit comments