generated from actions/typescript-action
-
Notifications
You must be signed in to change notification settings - Fork 27
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Current situation
Currently, the id or name of the job running the surge-preview action is used to create a specific Surge URL for the current deployment. This allows multiple surge deployments from a single workflow or multiple workflows.
The preview website URL is generated like this: https://{{repository.owner}}-{{repository.name}}-{{job.name}}-pr-{{pr.number}}.surge.sh
This job id/name is also used to identify the PR comment related to the deployment.
Drawbacks
- For long org or repo names, the subdomain can exceed 63 characters and become inaccessible (see surge-preview-tools: detect invalid domain name bonitasoft/actions#101). In this case, the job name must be changed, which is not convenient and reduces workflow readability.
- To support forked repos, several workflows are needed for deployment and teardown, and they need to share the same job id/name (see docs: explain usage to manage PR created from forked repositories #320).
- If the build process needs to know the Surge URL, it must use the same job id/name.
- Having the same job id/name is not natural for jobs not doing the same things is not natural, and not very explicit
Proposal
Introduce a new optional input called deploymentIdentifier (name can be discussed). It defaults to the job id/name (no breaking change).
- If set,
deploymentIdentifierwill be used instead of the job id/name when generating the Surge URL and for PR comment identification. - This input should only accept alpha-numeric characters.
This should make the process more flexible and thinks more explicit.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request