GitBook: [#216] Repository Group Configuration
BIN
.gitbook/assets/Screenshot 2023-01-10 at 3.02.42 PM.png
Normal file
|
After Width: | Height: | Size: 66 KiB |
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 137 KiB |
|
Before Width: | Height: | Size: 137 KiB After Width: | Height: | Size: 10 KiB |
BIN
.gitbook/assets/image (15) (1).png
Normal file
|
After Width: | Height: | Size: 303 KiB |
|
Before Width: | Height: | Size: 303 KiB After Width: | Height: | Size: 12 KiB |
BIN
.gitbook/assets/image (20) (1).png
Normal file
|
After Width: | Height: | Size: 285 KiB |
|
Before Width: | Height: | Size: 285 KiB After Width: | Height: | Size: 57 KiB |
BIN
.gitbook/assets/image (23) (1).png
Normal file
|
After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 32 KiB After Width: | Height: | Size: 57 KiB |
BIN
.gitbook/assets/image (5) (1).png
Normal file
|
After Width: | Height: | Size: 60 KiB |
|
Before Width: | Height: | Size: 60 KiB After Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 78 KiB After Width: | Height: | Size: 62 KiB |
|
Before Width: | Height: | Size: 62 KiB After Width: | Height: | Size: 78 KiB |
|
Before Width: | Height: | Size: 114 KiB |
|
Before Width: | Height: | Size: 555 KiB After Width: | Height: | Size: 114 KiB |
BIN
.gitbook/assets/image (9) (2).png
Normal file
|
After Width: | Height: | Size: 144 KiB |
|
Before Width: | Height: | Size: 144 KiB After Width: | Height: | Size: 77 KiB |
|
Before Width: | Height: | Size: 77 KiB After Width: | Height: | Size: 555 KiB |
@@ -20,6 +20,7 @@
|
||||
* [Configure an agent with Bitbucket Cloud access](how-to/on-premise-agent/configure-bitbucket-cloud-to-agent.md)
|
||||
* [Configure an agent with GitHub](how-to/on-premise-agent/configure-an-agent-with-github.md)
|
||||
* [Configure an agent with GitLab](how-to/on-premise-agent/configure-an-agent-with-gitlab.md)
|
||||
* [Configure Repository groups](how-to/on-premise-agent/configure-repository-groups.md)
|
||||
* [Artifact Repository Integration](how-to/on-premise-agent/maven-repository-integration/README.md)
|
||||
* [Maven repository integration overview](how-to/on-premise-agent/maven-repository-integration/maven-repository-integration-overview.md)
|
||||
* [Configure an agent with Maven repository access](how-to/on-premise-agent/maven-repository-integration/configure-an-agent-with-maven-repository-access.md)
|
||||
|
||||
@@ -14,11 +14,11 @@ Follow [this Atlassian guide](https://support.atlassian.com/bitbucket-cloud/docs
|
||||
|
||||
Configure the callback URL to point at your tenant:
|
||||
|
||||

|
||||
.png>)
|
||||
|
||||
The consumer should have these permissions:
|
||||
|
||||
.png>)
|
||||
 (5).png>)
|
||||
|
||||
* Projects - Read
|
||||
* Repositories - Write
|
||||
@@ -26,7 +26,7 @@ The consumer should have these permissions:
|
||||
|
||||
Take note of the key and secret on the newly formed consumer:
|
||||
|
||||
<figure><img src="../../.gitbook/assets/image (6).png" alt=""><figcaption></figcaption></figure>
|
||||
<figure><img src="../../.gitbook/assets/image (6) (3).png" alt=""><figcaption></figcaption></figure>
|
||||
|
||||
## Argument configuration
|
||||
|
||||
|
||||
80
how-to/on-premise-agent/configure-repository-groups.md
Normal file
@@ -0,0 +1,80 @@
|
||||
---
|
||||
description: >-
|
||||
Tenant-defined repository groups. Configure repository groups that will be
|
||||
available to all users.
|
||||
---
|
||||
|
||||
# Configure Repository groups
|
||||
|
||||
This guide will walk you through configuring global repository groups with the on-premise agent
|
||||
|
||||
#### Step 1 - Create repository\_groups.json file
|
||||
|
||||
1. [Create](../../references/managing-repository-groups.md#how-to-create-a-repository-group) and [export](../../references/managing-repository-groups.md#how-to-export-repository-groups-json) repository groups from the Moderne application. 
|
||||
2. Gather configuration from your team members and construct a `repository_groups.json` file:
|
||||
|
||||
```json
|
||||
{
|
||||
"Default": {
|
||||
"name": "Default",
|
||||
"description": null,
|
||||
"repositories": [
|
||||
{
|
||||
"origin": "github.com",
|
||||
"path": "Netflix/astyanax",
|
||||
"branch": "master",
|
||||
},
|
||||
{
|
||||
"origin": "github.com",
|
||||
"path": "Netflix/curator",
|
||||
"branch": "master",
|
||||
}
|
||||
]
|
||||
},
|
||||
"Servo": {
|
||||
"name": "Servo",
|
||||
"description": "servo clone",
|
||||
"repositories": [
|
||||
{
|
||||
"origin": "bitbucket.moderne.ninja:7999",
|
||||
"path": "mod/servo",
|
||||
"branch": "master",
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
#### Step 2 - Configure the Moderne Agent arguments
|
||||
|
||||
{% tabs %}
|
||||
{% tab title="OCI Container" %}
|
||||
Provide the path to the repository group for your container. 
|
||||
|
||||
* `MODERNE_AGENT_REPOSITORY_GROUP_FILE_PATH` - Application id configured in the previous step
|
||||
* Note: You must have the file containing the repository groups config mounted.
|
||||
|
||||
Example 
|
||||
|
||||
```
|
||||
docker run \
|
||||
...
|
||||
-e MODERNE_AGENT_REPOSITORY_GROUP_FILE_PATH=/app/repository_groups.json \
|
||||
...
|
||||
```
|
||||
{% endtab %}
|
||||
|
||||
{% tab title="Executable JAR" %}
|
||||
* `moderne.agent.repositoryGroupFilePath` - Application id configured in the previous step
|
||||
|
||||
Example
|
||||
|
||||
```
|
||||
java -jar moderne-agent-{version}.jar \
|
||||
...
|
||||
--moderne.agent.repositoryGroupFilePath=/app/repository_groups.json \
|
||||
...
|
||||
```
|
||||
{% endtab %}
|
||||
{% endtabs %}
|
||||
|
||||
@@ -50,7 +50,7 @@ Think of this like a static analyzer but with auto-remediation!
|
||||
|
||||
The `requestedRecipe` query parameter allows you to control which recipe will run. The recipe id for this query parameter can be copied from the recipe detail of any Terraform recipe on the Moderne platform.
|
||||
|
||||
.png>)
|
||||
 (1).png>)
|
||||
|
||||
4\. To connect this Task Event Hook to your workspace in Terraform Cloud, navigate to the
|
||||
|
||||
@@ -68,7 +68,7 @@ o **Advisory**: tasks can not block a run from completing. If the task fails, a
|
||||
|
||||
o **Mandatory**: tasks can block a run from completing. If the task fails (including a timeout or unexpected remote error condition), a warning will be displayed on the run and the run will transition to an Errored state.
|
||||
|
||||
 (1).png>)
|
||||
.png>)
|
||||
|
||||
Congratulations, your workspace is now set-up with your \<Partner> Integration!\\
|
||||
|
||||
@@ -78,7 +78,7 @@ You should be able to complete the next scenarios as your org admin user or as a
|
||||
|
||||
When all tasks pass, a run should be applyable. Whether a task passes or fails, you will be provided with a details link that links to the Moderne platform to display the result of the recipe that the task ran.
|
||||
|
||||
.png>)
|
||||
 (2).png>)
|
||||
|
||||
When a task fails, you can expect to see a diff in the Moderne platform along with commit and PR links that help you immediately fix the underlying issue.
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ Regardless of whether you choose to initiate an action to direct commit the chan
|
||||
|
||||
To illustrate the reconciliation process, suppose you are attempting to make a direct commit to the main branch of the remote.
|
||||
|
||||
<img src="../.gitbook/assets/image (20).png" alt="" data-size="original">
|
||||
<img src="../.gitbook/assets/image (20) (1).png" alt="" data-size="original">
|
||||
|
||||
In this example, the AST that Moderne is operating on was produced from commit b93f7b8, which at that time was the latest head of the main branch. However, between the build of the AST and when we initiate this commit action, there has been more commits on the main branch.
|
||||
|
||||
|
||||
@@ -4,60 +4,78 @@ When running recipes in Moderne, it's a good idea to filter them to run on a sel
|
||||
|
||||
To help you get started with repository groups, in this guide you will learn:
|
||||
|
||||
* [How to create a repository group](#how-to-create-a-repository-group)
|
||||
* [How to modify or delete an existing repository group](#how-to-modify-or-delete-existing-repository-groups)
|
||||
* [How to create a repository group](managing-repository-groups.md#how-to-create-a-repository-group)
|
||||
* [How to modify or delete an existing repository group](managing-repository-groups.md#how-to-modify-or-delete-existing-repository-groups)
|
||||
* [How to Export repository groups JSON](managing-repository-groups.md#how-to-export-repository-groups-json)
|
||||
|
||||
## How to create a repository group
|
||||
|
||||
1. In the top right corner of the Moderne home page, you will see some text to the left of your avatar that says `Default`:
|
||||
1. In the top right corner of the Moderne home page, you will see some text to the left of your avatar that says `Default`:
|
||||
|
||||

|
||||
|
||||
2. If you click on that, the repository group menu will appear:
|
||||
2. If you click on that, the repository group menu will appear:
|
||||
|
||||

|
||||
|
||||
3. Press `Create a repository group`. You will be taken to the repository group creation page:
|
||||
3. Press `Create a repository group`. You will be taken to the repository group creation page:
|
||||
|
||||

|
||||
4. At the top, you should enter a descriptive name for the group. This will be the identifier you'll see when you go to select which group you want to run a recipe on.
|
||||
5. Once you've entered a name, it's time to select the repositories you want to be included in this group. You can filter which repositories to add to your group by pressing the `Add Filter` button.
|
||||
|
||||
4. At the top, you should enter a descriptive name for the group. This will be the identifier you'll see when you go to select which group you want to run a recipe on.
|
||||
|
||||
5. Once you've entered a name, it's time to select the repositories you want to be included in this group. You can filter which repositories to add to your group by pressing the `Add Filter` button.
|
||||
* Please note that you can add more than one filter. If you do, the filters are additive — meaning that if you select both `openrewrite` and `moderne`, you will get all repositories that belong to either one of those organizations:
|
||||
* Please note that you can add more than one filter. If you do, the filters are additive — meaning that if you select both `openrewrite` and `moderne`, you will get all repositories that belong to either one of those organizations:
|
||||
|
||||

|
||||
|
||||
6. When you've finished adding filters, press the `>>` arrows in the middle of the screen to confirm your selection:
|
||||
6. When you've finished adding filters, press the `>>` arrows in the middle of the screen to confirm your selection:
|
||||
|
||||

|
||||
|
||||
7. Next, click on the `Save` button in the bottom right to create the group. You will be redirected to a page that displays all of your repository groups:
|
||||
7. Next, click on the `Save` button in the bottom right to create the group. You will be redirected to a page that displays all of your repository groups:
|
||||
|
||||

|
||||
|
||||
8. Now, when you go to run any recipe, you can click on the group name in the top right corner of the screen to select which repository group you want to run the recipe on:
|
||||
8. Now, when you go to run any recipe, you can click on the group name in the top right corner of the screen to select which repository group you want to run the recipe on:
|
||||
|
||||

|
||||
|
||||
## How to modify or delete existing repository groups
|
||||
|
||||
1. From any page, click on the text to the left of your avatar:
|
||||
1. From any page, click on the text to the left of your avatar:
|
||||
|
||||

|
||||
2. This will make the repository group menu appear:
|
||||
|
||||

|
||||
3. Click on `Manage Repository Groups`. You will be redirected to the repository group page:
|
||||
|
||||

|
||||
4. To modify a repository group, press the wrench icon under actions.
|
||||
5. To remove a repository group, press the trash can icon under actions.
|
||||
|
||||
## How to export repository groups JSON
|
||||
|
||||
1. From any page, click on the text to the left of your avatar:\
|
||||
\
|
||||
|
||||
|
||||
<figure><img src="../.gitbook/assets/image (15).png" alt=""><figcaption></figcaption></figure>
|
||||
|
||||
|
||||
2. This will make the repository group menu appear:
|
||||
|
||||

|
||||
<figure><img src="../.gitbook/assets/image (5).png" alt=""><figcaption></figcaption></figure>
|
||||
|
||||
3. Click on `Manage Repository Groups`. You will be redirected to the repository group page:
|
||||
3\. Click on `Manage Repository Groups`. You will be redirected to the repository group page:\
|
||||
|
||||

|
||||
|
||||
4. To modify a repository group, press the wrench icon under actions.
|
||||
<figure><img src="../.gitbook/assets/image (23).png" alt=""><figcaption></figcaption></figure>
|
||||
|
||||
5. To remove a repository group, press the trash can icon under actions.
|
||||
4\. You can then export them individually or you can export all of the repository groups defined. 
|
||||
|
||||
|
||||
|
||||
* To export an individual group, click the triple dots on the group you wish to export and then click on `Export repository group` from the menu. A `.json` file will be downloaded containing this single group.
|
||||
* To export all of the repository groups, click the `Export ALL` link. A `.json` file of all your groups will be downloaded.
|
||||
|
||||
<figure><img src="../.gitbook/assets/Screenshot 2023-01-10 at 3.02.42 PM.png" alt=""><figcaption></figcaption></figure>
|
||||
|
||||
## Additional information
|
||||
|
||||
Repository groups are saved locally in your browser. This means that no one else in your organization or team will be able to see the groups you've created. Likewise, if you switch to a different computer or browser, your groups will not exist there.
|
||||
Repository groups are saved locally in your browser. This means that no one else in your organization or team will be able to see the groups you've created. Likewise, if you switch to a different computer or browser, your groups will not exist there.
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
#### Admin token management
|
||||
|
||||
We have added the ability for admins to view and revoke Moderne personal access tokens of any user. There is now a new Access tokens page under the admin navigations:\
|
||||
.png>)\
|
||||
 (1).png>)\
|
||||
|
||||
|
||||
#### Improved keyboard shortcuts
|
||||
@@ -32,7 +32,7 @@ These tests currently come in two variants:
|
||||
* `singleSource` - The custom recipe will _**only be run on those source files**_ that would have been changed by _**all**_ `singleSource` test recipes. 
|
||||
* `anySource` - The custom recipe will run on _**all**_ _**source files**_ if there would have been a change from all `anySource` tests. Not all `anySource` tests have to change the _**same**_ file; as long as there would be one change from each test then the custom recipe would be run.
|
||||
|
||||
<figure><img src="../.gitbook/assets/image (8).png" alt=""><figcaption><p>For more information on applicability test see the <a href="https://docs.openrewrite.org/authoring-recipes/recipe-conventions-and-best-practices#use-applicability-tests">OpenRewrite documentation</a>.</p></figcaption></figure>
|
||||
<figure><img src="../.gitbook/assets/image.png" alt=""><figcaption><p>For more information on applicability test see the <a href="https://docs.openrewrite.org/authoring-recipes/recipe-conventions-and-best-practices#use-applicability-tests">OpenRewrite documentation</a>.</p></figcaption></figure>
|
||||
|
||||
### UI v 9.29.0 (2022/12/14)
|
||||
|
||||
@@ -84,7 +84,7 @@ This has been added to the following pages: 
|
||||
|
||||
You can now hide whitespace changes from diffs via the _Settings_ menu
|
||||
|
||||
<figure><img src="../.gitbook/assets/image (6) (3).png" alt=""><figcaption></figcaption></figure>
|
||||
<figure><img src="../.gitbook/assets/image (6).png" alt=""><figcaption></figcaption></figure>
|
||||
|
||||
### UI v9.21.0 (2022/11/18)
|
||||
|
||||
@@ -92,7 +92,7 @@ You can now hide whitespace changes from diffs via the _Settings_ menu
|
||||
|
||||
Now it's even easier to filter down the result set to only those diffs that include errors from the result diff menu bar.
|
||||
|
||||
<figure><img src="../.gitbook/assets/image (1) (5).png" alt=""><figcaption></figcaption></figure>
|
||||
<figure><img src="../.gitbook/assets/image (1).png" alt=""><figcaption></figcaption></figure>
|
||||
|
||||
### UI v9.15.0 (2022/11/03)
|
||||
|
||||
|
||||