Short references support protocol and transport

Problem

We plan to move the default steps distribution protocol to be OCI (instead of Git). So we should require the protocol and transport explicitly for the current short form which defaults to Git.

Adding short-references to support new protocols/transports should not result in changes to current short reference formats.

Proposal

Step references should be separated into a primary protocol followed by a transport mechanism, for example:

job:
  run:
    - name: my_git_https_step
      step: git+https://gitlab.com/project

This convention follows what others use in the industry, with tools such as npm and pip using a similar format.

Changes to short step references

Before After Notes
gitlab.com/project git+https://gitlab.com/project Omitting protocol/transport no longer defaults to git
./path/to/step file://path/to/step File can still be inferred using ./, should also support file://
builtin://oci/publish builtin://oci/publish No change.
n/a oci+https://registry.gitlab.com/project No change, omitting protocol/transport defaults to oci

Potential future short step references

Examples of what could be built in future (not necessarily what will be built). Implementing any of these will not require currently defined short step references to change.

  • git+ssh://
  • git+git:// (or just git:// for native Git protocol)
  • oci+ssh://
  • oci+file://
  • zip+file:// (or just zip://)
  • zip+https://
Edited by Cameron Swords