Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
112 changes: 112 additions & 0 deletions src/pages/docs/platform-hub/policies/deleting-policies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,112 @@
---
layout: src/layouts/Default.astro
pubDate: 2026-12-02
modDate: 2026-12-02
title: Deleting policies
subtitle: How to delete policies and their published versions from Platform Hub
icon: fa-solid fa-lock
navTitle: Deleting policies
navSection: Policies
description: How to delete policies from Platform Hub, including their published versions
navOrder: 166
---

When you no longer need a policy, you can delete it from Platform Hub. Deleting a policy removes its OCL file from your Git repository and its published versions from Octopus.

You can delete a policy from the branch or tag you're viewing. Octopus only deletes the versions published from that branch or tag, unless you choose to delete all versions from the default branch.

If you only want Octopus to stop evaluating a policy, deactivate it instead. You can re-activate it again later.

:::div{.hint}
You need the **PlatformHubEdit** permission to delete a policy.
:::

## Before you delete a policy

You can't delete a policy's active version. Deactivate the policy from the **Versions** tab on the edit policy page first.

- When you delete a policy from a branch or tag, Octopus prevents the delete if the active version was published from that branch or tag. An active version published from somewhere else doesn't stop the delete.
- When you delete all versions, Octopus prevents the delete if any version is active.

## Delete a policy

1. In Platform Hub, go to **Policies**.
2. Select the branch you want to delete the policy from.
3. Open the overflow menu (**...**) for the policy and select **Delete**.
4. On the default branch, choose which versions to delete. See [Delete all versions](#delete-all-versions).
5. Select **Delete**.

Octopus commits the change to the branch and deletes the versions published from that branch.

:::div{.warning}
You can't undo deleting a policy.
:::

### What Octopus deletes

| Where you delete from | Git repository | Published versions |
| --- | --- | --- |
| A branch | Removes the policy's OCL file from that branch | Deletes the versions published from that branch |
| The default branch, with **All versions** selected | Removes the policy's OCL file from the default branch | Deletes every version, wherever it was published from |
| A tag | No change | Deletes the versions published from that tag |

Octopus never changes the policy's file on other branches or tags.

Deleting a policy doesn't remove its history. Policy evaluations already recorded in the audit log and in task logs stay, and Octopus records the delete in the audit log.

### Delete all versions

On the default branch, the delete dialog asks **Which versions do you want to delete?** when other branches or tags have published versions of the policy:

- **Only versions from** the default branch deletes the versions published from the default branch. This is the default.
- **All versions** deletes every published version of the policy, including versions published from other branches, tags, and branches or tags that no longer exist.

You can only delete all versions from the default branch. **All versions** is unavailable while the policy has an active version.

### Delete versions published from a tag

A tag can't be changed, so Octopus doesn't remove the policy's file from a tag. Instead, you can delete the versions published from it.

1. Select the tag in the branch selector.
2. Open the overflow menu (**...**) for the policy and select **Delete versions**.
3. Select **Delete versions**.

**Delete versions** is only available when the policy has versions published from the tag.

## Protected branches

You can't delete a policy from a protected branch, because Octopus can't commit to it. **Delete** is unavailable and shows that the branch is protected.

To delete a policy from a protected branch:

1. Remove the policy in a pull request. You can delete the policy from an unprotected branch in Octopus, then select **Create pull request** next to the branch selector. This link is available when your Platform Hub repository is hosted on github.com or gitlab.com.
2. Merge the pull request into the protected branch.
3. In Octopus, select the protected branch. The policy now shows as **Removed from Git**.
4. Delete the policy. See [Policies removed from Git](#policies-removed-from-git).

## Policies removed from Git

When a policy's OCL file is removed from a branch outside Octopus, such as through a pull request, the versions published from that branch still exist in Octopus. If one of those versions is active, Octopus keeps evaluating it. The policy stays in the list with a **Removed from Git** status so you can clean it up.

Renaming a policy's OCL file has the same effect, because the file name is the policy's slug. The old name shows as **Removed from Git**, and the new name appears as a policy that hasn't been published.

For a policy that's been removed from Git, you can:

- Deactivate it
- Delete it, including on a protected branch

Octopus only deletes the published versions, and doesn't commit anything to your repository.

You can't open, edit, or publish a policy that's been removed from Git.

## Removed branches and tags

When a branch or tag is deleted from your Git repository, the policy versions published from it still exist in Octopus. The branch selector keeps listing the branch or tag with a **Removed** label for as long as it has published versions.

Select a removed branch or tag to see the policies with versions published from it. Each policy shows as **Removed from Git**. You can deactivate and delete these policies, but you can't create or edit policies there.

After you delete the last policy with versions published from a removed branch or tag, it no longer appears in the branch selector.

## Version notes

- Deleting policies with their published versions is available from Octopus Server 2027.1.x.
6 changes: 4 additions & 2 deletions src/pages/docs/platform-hub/policies/index.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
layout: src/layouts/Default.astro
pubDate: 2025-09-11
modDate: 2026-06-19
modDate: 2026-12-02
title: Policies
subtitle: Enforce deployment standards automatically across your Octopus instance
icon: fa-solid fa-lock
Expand Down Expand Up @@ -225,6 +225,8 @@ After committing, publish the policy to make the changes take effect. Choose the

The first time you publish a policy, you can only publish a major version.

You can publish a policy from a branch or a tag. You can't publish from a commit.

:::

:::figure
Expand All @@ -233,7 +235,7 @@ The first time you publish a policy, you can only publish a major version.

### 10. Activate your policy

Published policies must be activated before Octopus evaluates them. You can deactivate a policy at any time to stop it from being evaluated without deleting it.
Published policies must be activated before Octopus evaluates them. You can deactivate a policy at any time to stop it from being evaluated without deleting it. If you no longer need a policy, see [Deleting policies](/docs/platform-hub/policies/deleting-policies).

:::div{.hint}

Expand Down
154 changes: 154 additions & 0 deletions src/pages/docs/platform-hub/templates/deleting-templates.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,154 @@
---
layout: src/layouts/Default.astro
pubDate: 2026-12-02
modDate: 2026-12-02
title: Deleting templates
subtitle: How to delete process templates and project templates from Platform Hub
icon: fa-solid fa-layer-group
navTitle: Deleting templates
navSection: Templates
description: How to delete process templates and project templates from Platform Hub, including their published versions
navOrder: 148
---

When you no longer need a process template or project template, you can delete it from Platform Hub. Deleting a template removes its files from your Git repository and its published versions from Octopus, so a deleted template doesn't leave anything behind.

You can delete a template from the branch or tag you're viewing. Octopus only deletes the versions published from that branch or tag, unless you choose to delete all versions from the default branch.

:::div{.hint}
You need the **PlatformHubEdit** permission to delete a template.
:::

## Before you delete a template

Octopus only deletes a template when nothing depends on it. If you select **Delete** on a template that's still shared or in use, Octopus tells you what's stopping the delete.

These checks apply to the template on every branch and tag, not just the one you're viewing.

### Process templates

Before you delete a process template:

- Stop sharing it. A process template that's shared with all spaces or with specific spaces can't be deleted.
- Make sure no templated project gets it through a project template. See [Process templates used by project templates](#process-templates-used-by-project-templates).

Octopus doesn't check projects that use the process template directly in a deployment process or runbook. After you stop sharing a process template, those projects can't load it. Before you stop sharing, [see where the process template is used](/docs/platform-hub/templates/process-templates#see-where-a-process-template-is-used) and ask the project owners to remove it.

### Process templates used by project templates

A project template can include a process template in its deployment process. You can't delete a process template while any of the following is true:

- A templated project is on a project template version that uses the process template.
- A templated project can update to a project template version that uses the process template. A project on a stable version can update to the newest stable version in the same major version.
- The latest stable or latest pre-release version of a project template uses the process template, because new projects would get it. This applies even when no project uses the project template.

Older project template versions that no project is on, or can update to, don't stop the delete.

To remove a process template from use:

1. Publish a new version of the project template without the process template.
2. Ask project owners to update their projects to the latest version.

### Project templates

Before you delete a project template:

- Stop sharing it.
- Remove every project created from it. This includes projects in any space, on any version of the template, and disabled projects.

You can't detach a templated project from its project template. To see which projects use a project template, select the template's **Usage** column in the **Project Templates** list.

## Delete a template

1. In Platform Hub, go to **Process Templates** or **Project Templates**.
2. Select the branch you want to delete the template from.
3. Open the overflow menu (**...**) for the template and select **Delete**.
4. On the default branch, choose which versions to delete. See [Delete all versions](#delete-all-versions).
5. Select **Delete**.

Octopus commits the change to the branch and deletes the versions published from that branch.

:::div{.warning}
You can't undo deleting a template.
:::

### What Octopus deletes

| Where you delete from | Git repository | Published versions |
| --- | --- | --- |
| A branch | Removes the template's files from that branch | Deletes the versions published from that branch |
| The default branch, with **All versions** selected | Removes the template's files from the default branch | Deletes every version, wherever it was published from |
| A tag | No change | Deletes the versions published from that tag |

Octopus never changes the template's files on other branches or tags. If the template still exists on another branch, you can keep working on it there.

For a process template, Octopus removes a single OCL file. For a project template, Octopus removes the template's folder, including its deployment process, parameters, variables, channels, and lifecycles.

Octopus keeps a process template's sensitive parameter default values, and a project template's sensitive variables, while another branch or tag still has published versions of the template. Octopus deletes them when you delete all versions. It also deletes them when no other branch or tag has published versions and the template is no longer on the default branch.

### Delete all versions

On the default branch, the delete dialog asks **Which versions do you want to delete?** when other branches or tags have published versions of the template:

- **Only versions from** the default branch deletes the versions published from the default branch. This is the default.
- **All versions** deletes every published version of the template, including versions published from other branches, tags, and branches or tags that no longer exist.

You can only delete all versions from the default branch.

### Delete versions published from a tag

A tag can't be changed, so Octopus doesn't remove the template's files from a tag. Instead, you can delete the versions published from it.

1. Select the tag in the branch selector.
2. Open the overflow menu (**...**) for the template and select **Delete versions**.
3. Select **Delete versions**.

**Delete versions** is only available when the template has versions published from the tag.

## Protected branches

You can't delete a template from a protected branch, because Octopus can't commit to it. **Delete** is unavailable and shows that the branch is protected.

To delete a template from a protected branch:

1. Remove the template in a pull request. You can delete the template from an unprotected branch in Octopus, then select **Create pull request** next to the branch selector. This link is available when your Platform Hub repository is hosted on github.com or gitlab.com.
2. Merge the pull request into the protected branch.
3. In Octopus, select the protected branch. The template now shows as **Removed from Git**.
4. Delete the template. See [Templates removed from Git](#templates-removed-from-git).

## Templates removed from Git

When a template's files are removed from a branch outside Octopus, such as through a pull request, the versions published from that branch still exist in Octopus. The template stays in the list with a **Removed from Git** status so you can clean it up.

Renaming a process template's OCL file or a project template's folder has the same effect, because the name is the template's slug. The old name shows as **Removed from Git**, and the new name appears as a template that hasn't been published.

For a template that's been removed from Git, you can:

- Stop sharing it
- Delete it, including on a protected branch

Octopus only deletes the published versions, and doesn't commit anything to your repository.

You can't open, edit, share, or publish a template that's been removed from Git.

## Removed branches and tags

When a branch or tag is deleted from your Git repository, the versions published from it still exist in Octopus. The branch selector keeps listing the branch or tag with a **Removed** label for as long as it has published versions.

Select a removed branch or tag to see the templates with versions published from it. Each template shows as **Removed from Git**. You can stop sharing and delete these templates, but you can't create or edit templates there.

After you delete the last template with versions published from a removed branch or tag, it no longer appears in the branch selector.

## After you delete a template

Existing releases and runbook snapshots that use a deleted process template can still be deployed and run. They keep their own copy of what they need from the template.

If you create a new template with the same name as a deleted one, it starts fresh only when no other branch or tag still has published versions of the old template. If you want to reuse a name, delete all versions first.

:::div{.warning}
Octopus stops you deleting a Platform Hub certificate that a published template version uses. After you delete a template, Octopus no longer knows that existing releases use the certificate, and lets you delete it. Deploying those releases then fails. Before you delete a certificate that a deleted template used, check that you no longer need to deploy those releases.
:::

## Version notes

- Deleting process templates and project templates with their published versions is available from Octopus Server 2027.1.x.
24 changes: 23 additions & 1 deletion src/pages/docs/platform-hub/templates/process-templates/index.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
layout: src/layouts/Default.astro
pubDate: 2025-09-23
modDate: 2026-11-04
modDate: 2026-12-02
title: Process Templates
subtitle: An overview of Process Templates
icon: fa-solid fa-layer-group
Expand Down Expand Up @@ -123,6 +123,27 @@ When a process template is used inside a project, the project supplied values wi

Once you've configured your process template, see [Publishing and sharing templates](/docs/platform-hub/templates/publishing-and-sharing) for how to commit, publish, and share it.

## See where a process template is used

The **Sharing** column in the **Process Templates** list shows whether a process template is shared with all spaces, with specific spaces, or not shared. Select it to see where the process template is used.

The dialog lists:

- **Projects**: Each project that uses the process template, with its space, whether it's used in the deployment process or a runbook, and the version range the project accepts.
- **Project templates**: Each project template version that uses the process template, and the templated projects on that version or able to update to it.

The list covers projects stored in Octopus, their runbooks, templated projects, and the latest project template versions. It doesn't include version-controlled projects, or project template changes that haven't been published.

:::div{.hint}
Anyone with the **PlatformHubView** permission sees every project that uses the process template, including projects in spaces they can't access.
:::

After you upgrade Octopus Server, Octopus checks the deployment processes and runbooks saved before the upgrade. Until it finishes, the dialog tells you that some projects might not be listed yet. This can take a while on large instances.

## Deleting a process template

When you no longer need a process template, you can delete it along with its published versions. See [Deleting templates](/docs/platform-hub/templates/deleting-templates).

## A Hello world deployment process in a process template

To define a simple deployment process in Octopus that executes a hello world script on the Octopus Server, complete the following steps:
Expand Down Expand Up @@ -155,3 +176,4 @@ You can now deploy this process to say "Hello, World!".
## Version notes

- Creating a parameter from a step in the process editor is available in Octopus Deploy versions `>= 2026.4.11453`.
- Seeing where a process template is used, and [deleting a process template](/docs/platform-hub/templates/deleting-templates) with its published versions, are available from Octopus Server 2027.1.x.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
layout: src/layouts/Default.astro
pubDate: 2025-09-23
modDate: 2026-12-01
modDate: 2026-12-02
title: Troubleshooting
subtitle: Known issues that you may run into
icon: fa-solid fa-layer-group
Expand Down Expand Up @@ -101,6 +101,17 @@ When deploying to the **Development** environment, **Account-124** would be used

<br>

### Sensitive default value not found

A process template's sensitive parameter default values are stored in Octopus, not in the template's OCL file. If the stored value is missing, the process template shows **Sensitive default value not found** and names the parameters affected. You can't publish the process template until you fix them.

This can happen when:

- The process template was [deleted](/docs/platform-hub/templates/deleting-templates) from another branch, and no published versions were left
- The process template's OCL file was copied to a new name or another repository

To fix it, enter a new default value for each parameter or remove the default, then commit and publish.

### Step specific issues

- You cannot configure **Edit YAML** on the **Configure and apply Kubernetes resource** step.
Expand Down
Loading