Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This change adds support for organizations. It does so by adding an optional
--org
argument to thephylum-ci
entry point. That argument will take precedence over any value found in the Phylum settings file. The argument and all the logic and documentation around it allow for no org to be specified. This is intentional since there will have to be a transition period where some users may not be using orgs just yet.When an org is specified, it is required that a group also be specified. However, it is still possible to specify a group without an org and even no group at all. The log output was updated to make it more clear which project/org/group combo is in use.
Additional changes made include:
ci
Phylum analysis extension--org
option and use it when callingPhylumApi::analyze
phylum project status
json outputrepository_url
torepositoryUrl
repo_url
entries were overwritten_cmd_extender
helper function to add common CLI optionsOSError
exception instead of more specific oneBREAKING CHANGE: Phylum CLI installs before v7.1.4-rc1 are no longer supported. That release is the first one providing support for analysis with organizations via extensions.
Testing
The changes in this PR are available for testing with the
maxrake/phylum-ci:orgs
Docker image found on Docker Hub.The changes were tested explicitly for each of the following scenarios:
settings.yaml
file only--org
option onlysettings.yaml
file and--org
optionTODO
A separate PR in the
phylum-analyze-pr-action
repository will be created to update the documentation there. That PR won't be merged until after the changes from this PR have been approved, merged, and a release created from it.