Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

all merges to main should auto-deploy to staging (in sequence), using prerelease by default unless otherwise specified #427

Open
josefaidt opened this issue Apr 4, 2023 · 0 comments
Labels
area: infra Issue pertains to infrastructure (CDK) type: feature-request New feature or request

Comments

@josefaidt
Copy link
Contributor

Describe the Feature

Currently deployments to the staging environment, "next", are created and invoked manually via GitHub Actions. It would be nice if every merge to the main branch automatically deployed to the staging environment. This may justify a need for semver-* labels to control what type of prerelease is created

flowchart TD
    PR[Pull Request]
    MAIN["primary git branch (main)"]

    ISPRLABELED[is PR labeled with semver-* ?]
    ISPRLABELEDYES[yes]
    ISPRLABELEDNO[no]

    RELEASEPRE["use prerelease (-next.x)"]
    RELEASEPREPATCH["use prepatch (x-next.0)"]
    RELEASEPREMINOR["use preminor (x.0-next.0)"]
    RELEASEPREMAJOR["use preminor (x.0.0-next.0)"]
  
    PR-->|is merged to|MAIN
    MAIN-->ISPRLABELED
    ISPRLABELED-->ISPRLABELEDYES
    ISPRLABELED-->ISPRLABELEDNO

    ISCURRENTPRE[is current package.json a prerelease?]
    ISCURRENTPREYES[yes]
    ISCURRENTPRENO[no]

    ISPRLABELEDNO-->ISCURRENTPRE
    ISCURRENTPRE-->ISCURRENTPREYES
    ISCURRENTPRE-->ISCURRENTPRENO

    ISCURRENTPREYES-->RELEASEPRE
    ISCURRENTPRENO-->|default to|RELEASEPREPATCH

    ISLABELEDMAJOR[is semver-major?]
    ISLABELEDMAJORYES[yes]
    ISLABELEDMAJORNO[no]
    ISLABELEDMINOR[is semver-minor?]
    ISLABELEDMINORYES[yes]
    ISLABELEDMINORNO[no]
    ISLABELEDPATCH[is semver-patch?]
    ISLABELEDPATCHYES[yes]
    ISLABELEDPATCHNO[no]

    ISPRLABELEDYES-->ISLABELEDMAJOR
    ISLABELEDMAJOR-->ISLABELEDMAJORYES
    ISLABELEDMAJOR-->ISLABELEDMAJORNO
    
    ISLABELEDMAJORYES-->RELEASEPREMAJOR
    ISLABELEDMAJORNO-->ISLABELEDMINOR
    ISLABELEDMINOR-->ISLABELEDMINORYES
    ISLABELEDMINOR-->ISLABELEDMINORNO

    ISLABELEDMINORYES-->RELEASEPREMINOR
    ISLABELEDMINORNO-->ISLABELEDPATCH
    ISLABELEDPATCH-->ISLABELEDPATCHYES
    ISLABELEDPATCH-->ISLABELEDPATCHNO

    ISLABELEDPATCHYES-->RELEASEPREPATCH
    ISLABELEDPATCHNO-->RELEASEPRE
Loading

Releases to production will still be manually-created

@josefaidt josefaidt added needs: triage type: feature-request New feature or request area: infra Issue pertains to infrastructure (CDK) and removed needs: triage labels Apr 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: infra Issue pertains to infrastructure (CDK) type: feature-request New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant