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: README.md
+54-2Lines changed: 54 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -86,7 +86,7 @@ This action can be configured to authenticate with GitHub App Installation or Pe
86
86
|`GH_APP_PRIVATE_KEY`| True |`""`| GitHub Application Private Key. See [documentation](https://docs.github.com/en/apps/creating-github-apps/authenticating-with-a-github-app/about-authentication-with-a-github-app) for more details. |
87
87
|`GITHUB_APP_ENTERPRISE_ONLY`| False | false | Set this input to `true` if your app is created in GHE and communicates with GHE. |
88
88
89
-
The needed GitHub app permissions are the following:
89
+
The needed GitHub app permissions are the following under `Repository permissions`:
90
90
91
91
-`Administration` - Read and Write (Needed to activate the [automated security updates](https://docs.github.com/en/code-security/dependabot/dependabot-security-updates/configuring-dependabot-security-updates#managing-dependabot-security-updates-for-your-repositories) )
92
92
-`Pull Requests` - Read and Write (If `TYPE` input is set to `pull`)
@@ -125,6 +125,58 @@ The needed GitHub app permissions are the following:
125
125
| `SCHEDULE` | False | `weekly` | Schedule interval by which to check for dependency updates via Dependabot. Allowed values are `daily`, `weekly`, or `monthly` |
126
126
| `SCHEDULE_DAY` | False | '' | Scheduled day by which to check for dependency updates via Dependabot. Allowed values are days of the week full names (i.e., `monday`) |
127
127
| `LABELS` | False | "" | A comma separated list of labels that should be added to pull requests opened by dependabot. |
128
+
| `DEPENDABOT_CONFIG_FILE` | False | "" | Location of the configuration file for `dependabot.yml` configurations. If the file is present locally it takes precedence over the one in the repository. |
129
+
130
+
### Private repositories configuration
131
+
132
+
Dependabot allows the configuration of [private registries](https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#configuration-options-for-private-registries) for dependabot to use.
133
+
To add a private registry configuration to the dependabot file the `DEPENDABOT_CONFIG_FILE` needs to be set with the path of the configuration file.
134
+
135
+
This configuration file needs to exist on the repository where the action runs. It can also be created locally to test some configurations (if created locally it takes precedence over the file on the repository).
136
+
137
+
#### Usage
138
+
139
+
Set the input variable:
140
+
141
+
```yaml
142
+
DEPENDABOT_CONFIG_FILE = "dependabot-config.yaml"
143
+
```
144
+
145
+
Create a file on your repository in the same path:
146
+
147
+
```yaml
148
+
npm:
149
+
type: "npm"
150
+
url: "https://yourprivateregistry/npm/"
151
+
username: "${{secrets.username}}"
152
+
password: "${{secrets.password}}"
153
+
key: <used if necessary>
154
+
token: <used if necessary>
155
+
replaces-base: <used if necessary>
156
+
maven:
157
+
type: "maven"
158
+
url: "https://yourprivateregistry/maven/"
159
+
username: "${{secrets.username}}"
160
+
password: "${{secrets.password}}"
161
+
```
162
+
163
+
The principal key of each configuration need to match the package managers that the [script is looking for](https://github.com/github/evergreen/blob/main/dependabot_file.py#L78).
164
+
165
+
The `dependabot.yaml` created file will look like the following with the `registries:` key added:
0 commit comments