Skip to content

Commit

Permalink
Update UseCase-ParentChildProjects.md
Browse files Browse the repository at this point in the history
  • Loading branch information
BobJWalker authored Feb 4, 2022
1 parent 1a5d5fd commit bf44f26
Showing 1 changed file with 57 additions and 3 deletions.
60 changes: 57 additions & 3 deletions docs/UseCase-ParentChildProjects.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ Options:
- `OverwriteExistingCustomStepTemplates` - Set to `true` as you'll want to make sure you have the latest step templates.
- `OverwriteExistingLifecyclesPhases` - Set to `false` because you've most likely have a unique lifecycle.
- `CloneProjectChannelRules` - set to `false` as the project already exists with its own rules.
- `CloneTeamUserRoleScoping` - set to `false` as you won't want to overwrite team user role scoping.
- `CloneProjectVersioningReleaseCreationSettings` - set to `false` as you'll want to exclude the release creation settings.
- `CloneProjectDeploymentProcess` - set to `true` as you'll want to include the project deployment process.
- `CloneProjectRunbooks` - set to `true` as you'll want to include the project runbooks.
Expand All @@ -31,8 +30,7 @@ CloneSpace.ps1 -SourceOctopusUrl "https://instance1.yoursite.com" `
-OverwriteExistingVariables "false" `
-OverwriteExistingCustomStepTemplates "true" `
-OverwriteExistingLifecyclesPhases "false" `
-CloneProjectChannelRules "false" `
-CloneTeamUserRoleScoping "false" `
-CloneProjectChannelRules "false" `
-CloneProjectVersioningReleaseCreationSettings "false" `
-CloneProjectRunbooks "true" `
-CloneProjectDeploymentProcess "true"
Expand Down Expand Up @@ -63,3 +61,59 @@ CloneSpace.ps1 -SourceOctopusUrl "https://instance1.yoursite.com" `
-CloneProjectRunbooks "true" `
-CloneProjectDeploymentProcess "true"
```

# Example - Clone a runbook between projects in the same space

This example is syncing the parent project in the same space.

Please refer to the [Parameter reference page](CloneSpaceParameterReference.md) for more details on the parameters.

Options:
- `OverwriteExistingVariables` - set to `false` to keep the differences preserved. Any new variable found will be added.
- `CloneProjectChannelRules` - set to `false` as you are not cloning the deployment process.
- `CloneProjectVersioningReleaseCreationSettings` - set to `false` as you are not cloning the deployment process.
- `CloneProjectDeploymentProcess` - set to `false` as you are not cloning the deployment process.
- `CloneProjectLogos` - set to `false` as you only want the runbook(s).
- `CloneProjectRunbooks` - set to `true` as you want to clone runbooks.
- `ProcessCloningOption` - set to `KeepAdditionalDestinationSteps` in the event you are cloning to an existing runbook
- `ProcessEnvironmentScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.
- `ProcessChannelScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.
- `ProcessTenantTagsScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.
- `VariableChannelScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.
- `VariableEnvironmentScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.
- `VariableProcessOwnerScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.
- `VariableActionScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.
- `VariableMachineScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.
- `VariableTenantTagsScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.
- `VariableAccountScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.
- `VariableCertificateScopingMatch` - set to `SkipUnlessPartialMatch` as you are cloning in the same space.

```PowerShell
CloneSpace.ps1 -SourceOctopusUrl "https://instance1.yoursite.com" `
-SourceOctopusApiKey "SOME KEY" `
-SourceSpaceName "My Space Name" `
-DestinationOctopusUrl "https://instance1.yoursite.com" `
-DestinationOctopusApiKey "My Key" `
-DestinationSpaceName "New Space Name" `
-ParentProjectName "Redgate - Feature Branch Example" `
-ChildProjectsToSync "Redgate - Child*" `
-RunbooksToClone "YOUR RUNBOOK NAME" `
-OverwriteExistingVariables "false" `
-CloneProjectChannelRules "false" `
-CloneProjectVersioningReleaseCreationSettings "false" `
-CloneProjectDeploymentProcess "false" `
-CloneProjectLogos "false" `
-CloneProjectRunbooks "true" `
-ProcessCloningOption "KeepAdditionalDestinationSteps" `
-ProcessEnvironmentScopingMatch "SkipUnlessPartialMatch" `
-ProcessChannelScopingMatch "SkipUnlessPartialMatch" `
-ProcessTenantTagsScopingMatch "SkipUnlessPartialMatch" `
-VariableChannelScopingMatch "SkipUnlessPartialMatch" `
-VariableEnvironmentScopingMatch "SkipUnlessPartialMatch" `
-VariableProcessOwnerScopingMatch "SkipUnlessPartialMatch" `
-VariableActionScopingMatch "SkipUnlessPartialMatch" `
-VariableMachineScopingMatch "SkipUnlessPartialMatch" `
-VariableTenantTagsScopingMatch "SkipUnlessPartialMatch" `
-VariableAccountScopingMatch "SkipUnlessPartialMatch" `
-VariableCertificateScopingMatch "SkipUnlessPartialMatch"
```

0 comments on commit bf44f26

Please sign in to comment.