Skip to content

Old Multidevs not being deleted #51

@maskedjellybean

Description

@maskedjellybean

During the build process there is a step called "Delete old Multidevs to make space for a new one". This does not work, which eventually causes builds to fail until I manually delete old Multidevs.

I can see the reason why but I'm not sure how to fix it. The build step output looks like this:

#!/bin/bash -eo pipefail
terminus -n build:env:delete:ci "$TERMINUS_SITE" --keep=2 --yes
 [notice] No environments matched the provided pattern "ci-".
CircleCI received exit code 0

Notice that it is looking for Multidevs that start with "ci-". None of the Multidevs created by this orb start with "ci-". They all start with "pr-". This makes some sense because our workflow is based on pull requests and looks like this:

  • Branch off of master to work on a feature.
  • Create a PR on Github to merge the feature branch back into master.
  • CircleCI automatically creates a Multidev env representing the merge of the PR. The Multidev is named starting with "pr-".
  • After QA on the Multidev, the PR is merged on Github. CircleCI automatically deploys to Dev env. (at the point the Multidev is no longer needed and could be deleted)

Is there any way for the "Delete old Multidevs to make space for a new one" step to delete Multidevs whose PR has been merged? If not, what is the purpose of this step?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions