moving sections around

This commit is contained in:
leanne
2025-03-10 14:53:32 -07:00
parent 720113c279
commit f98b346174

View File

@@ -5,6 +5,48 @@ import TabItem from '@theme/TabItem';
In order for Moderne to obtain information about your organizational structure, you will need to create some configuration files and direct the Moderne agent to said files. This guide will explain how to do both of those things.
## repos.csv
This is a required file, which outlines the repositories and the organizations which they are associated with.
When provided your organization details, they must be provided in a CSV file with the following format:
| cloneUrl | branch | org1 | org2 | org3 |
|---------------|----------|---------|-------------|------|
| `https://github.com/openrewrite/rewrite-recipe-bom` | main | Open Source | ALL | |
| `https://github.com/Netflix/spectator-go` | main | Netflix | Open Source | ALL |
The organizations under `org1`, `org2`, `org3`, etc. represent the hierarchy of organizations. There is no limit to the number of organizations that can be provided via this CSV.
The above example would be used in Moderne DX to generate an organizational listing of the following:
* ALL
* Open Source
* `https://github.com/openrewrite/rewrite-recipe-bom:main`
* Netflix
* `https://github.com/Netflix/spectator-go:main`
To generate this `repos.csv`, we recommend using "[repo fetchers](https://github.com/moderneinc/repository-fetchers)".
## commitOptions.txt
This is an optional file, which allows for custom commit options for individual repositories. When no commit options are provided for a specific repositories we will use the default commit options which are specified in that [agent configuration](agent-variables.md#all-agent-configuration-variables) or all commit options if no default are provided.
If you want to provide specific commit options for specific repositories, these can be provided in a text file with the following format:
```text
My_Organzation_ID_1=Branch,PullRequest
My_Organzation_ID_2=Branch,Direct,PullRequest
```
## idMapping.txt
This is an optional file, which set an organization name. By default an organization name is the same as its ID.
These can be overwritten by provided a text file with the following format:
```text
My_Organzation_ID_1=My_Organzation_Name_1
My_Organzation_ID_2=My_Organzation_Name_2
```
## devCenter.json
This is an optional file, which is used to generate the DevCenter. For more details about configuring your DevCenter please reference this [guide](../dev-center.md#step-3-create-and-configure-the-devcenter).
The provided devCenter.json should follow the structure of this [file](https://github.com/moderneinc/moderne-organizations/blob/main/src/main/resources/devcenter.json).
## Agent Configurations
<Tabs groupId="agent-type">
<TabItem value="oci-container" label="OCI Container">
@@ -51,42 +93,3 @@ java -jar moderne-agent-{version}.jar \
</TabItem>
</Tabs>
## Generating repos.csv
When provided your organization details, they must be provided in a CSV file with the following format:
| cloneUrl | branch | org1 | org2 | org3 |
|---------------|----------|---------|-------------|------|
| `https://github.com/openrewrite/rewrite-recipe-bom` | main | Open Source | ALL | |
| `https://github.com/Netflix/spectator-go` | main | Netflix | Open Source | ALL |
The organizations under `org1`, `org2`, `org3`, etc. represent the hierarchy of organizations. There is no limit to the number of organizations that can be provided via this CSV.
The above example would be used in Moderne DX to generate an organizational listing of the following:
* ALL
* Open Source
* `https://github.com/openrewrite/rewrite-recipe-bom:main`
* Netflix
* `https://github.com/Netflix/spectator-go:main`
To generate this `repos.csv`, we recommend using "[repo fetchers](https://github.com/moderneinc/repository-fetchers)".
## Generating commitOptions.txt
If you want to provide specific commit options for specific repositories, these can be provided in a text file with the following format:
```text
My_Organzation_ID_1=Branch,PullRequest
My_Organzation_ID_2=Branch,Direct,PullRequest
```
Any organization not listed in this file will fall back to either default commit options.
## Generating idMapping.txt
By default an organization name is the same as its ID, if you want to change an organization name, these can be provided in a text file with the following format:
```text
My_Organzation_ID_1=My_Organzation_Name_1
My_Organzation_ID_2=My_Organzation_Name_2
```
## Generating devCenter.json
The provided devCenter.json should follow the structure of this [file](https://github.com/moderneinc/moderne-organizations/blob/main/src/main/resources/devcenter.json).
For more details about configuring your DevCenter please reference this [guide](../dev-center.md#step-3-create-and-configure-the-devcenter).