Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ortelius-cli

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ortelius-cli

  • 9.3.278
  • PyPI
  • Socket score

Maintainers
1

The Ortelius Command Line Interface

The Ortelius Command Line Interface supports integration with DevOps tools and CI/CD pipelines.

The CLI Python script interacts with the Ortelius REST APIs to perform:

  • Approve the Application Version
  • Move the _Application Version- using the supplied task
  • Create/replace the Component Version for the Application Version
  • Assign a Component Version to an Application version
  • Assign the key/values pairs to the Component version
  • Create a bash file from the Component .toml file
  • Export a Domain including all objects to stdout
  • Imports the export file into the new Domain
  • Deploy the Application Version
  • Upload Swagger and SBOM files to Component Version

CLI Prerequisites

  1. Install Python 3.8 or newer

  2. Install Ortelius CLI

    pip install --upgrade ortelius-cli

Get Started with a POC

Refer to the Ortelius sample POC to get started. This POC provides you the steps to incorporate Ortelius into your Pipeline, with SBOM generation.

Ortelius' CLI using the dhapi module

Arguments:

ACTION - one of the following

  • deploy - deploy the Application to the Environment Usage: --dhurl --dhuser --dhpass --appname --appversion (optional) --deployenv

  • approve - approve the Application Version Usage: --dhurl --dhuser --dhpass --appname --appversion (optional)

  • move - move the Application Version using the supplied task Usage: --dhurl --dhuser --dhpass --appname --appversion (optional) --from_domain --task

  • updatecomp - create/replace the Component Version for the Application Version with SBOM (CycloneDX or SPDX formats). Usage: --dhurl --dhuser --dhpass --rsp --autoappinc (optional) --compautoinc (optional) --consumes (optional) --provides (optional) --deppkg cyclonedx@ (optional) --deppkg spdx@ (optional)

Component TOML Definition for --rsp parameter
# Application Name and Version to create an associate the Component Version to
# NOTE: Only needed if you need to assoicate the Component Version to the Application Version

Application = ""          # Name of the Applcation including the full Domain Name
Application_Version = ""  # The semantic version for the Application Version

# Component Name, Variant and Version
Name = ""
Variant = "${GIT_BRANCH}"
Version = "v1.0.0.${BUILD_NUM}-g${GIT_COMMIT}"                  # 1.0.0 should be replace with your starting version string

# Export the derived IMAGE_TAG, DOCKERREPO values to the CI/CD Tool via a shell script when using the `envscript` command line action
[Export]
IMAGE_TAG = "${Variant}-${Version}"
DOCKERREPO = "${DockerRepo}"

# Key/Values to associate to the Component Version.  Custom key/values can be added under this section.
[Attributes]
BuildId = "${BUILDID}"                                      # Identifier for the CI job (DERIVED IF NOT SPECIFIED)
BuildNumber = "${BUILD_NUM}"                                # Build number for the CI job (DERIVED IF NOT SPECIFIED)
BuildUrl = "${BUILD_URL}"                                   # Build url for the CI job (DERIVED IF NOT SPECIFIED)
Chart = ""                                                  # Helm Chart for the Component
ChartNamespace = ""                                         # Name space for the Component to be deployed to
ChartRepo = ""                                              # Helm Chart Repo Name
ChartRepoUrl = ""                                           # Helm Chart Repo Url
ChartVersion = ""                                           # Helm Chart version
CustomAction = ""                                           # Custom Action to assign to the Component
DeployAlways = ""                                           # Set the Always Deploy option Y/N, default is N
DockerBuildDate = ""                                        # Timestamp when the image was created (DERIVED IF NOT SPECIFIED)
DockerRepo = "${DOCKERREPO}"                                # Registry which the image was pushed to
DockerSha = "${DIGEST}"                                     # Digest for the image (DERIVED IF NOT SPECIFIED)
DockerTag = "${DOCKERTAG}"                                  # Tag for the image
GitBranch = "${GIT_BRANCH}"                                 # Git branch in the git repo (DERIVED IF NOT SPECIFIED)
GitBranchCreateCommit = "${GIT_BRANCH_CREATE_COMMIT}"       # Git commit that the branch was created from (DERIVED IF NOT SPECIFIED)
GitBranchCreateTimestamp = "${GIT_BRANCH_CREATE_TIMESTAMP}" # Timestamp of when the branch was created (DERIVED IF NOT SPECIFIED)
GitBranchParent = "${GIT_BRANCH_PARENT}"                    # The parent branch for the current branch (DERIVED IF NOT SPECIFIED)
GitCommit = "${GIT_COMMIT}"                                 # Git commit that triggered the CI job (DERIVED IF NOT SPECIFIED)
GitCommitAuthors = "${GIT_COMMIT_AUTHORS}"                  # List of committers for the repo (DERIVED IF NOT SPECIFIED)
GitCommittersCnt = "${GIT_COMMITTERS_CNT}"                  # Count of GitCommitAuthors (DERIVED IF NOT SPECIFIED)
GitCommitTimestamp = "${GIT_COMMIT_TIMESTAMP}"              # Timestamp of the current commit (DERIVED IF NOT SPECIFIED)
GitContribPercentage = "${GIT_CONTRIB_PERCENTAGE}"          # GitCommittersCnt / GitTotalCommittersCnt * 100 (DERIVED IF NOT SPECIFIED)
GitLinesAdded = "${GIT_LINES_ADDED}"                        # Lines added since the previous commit (DERIVED IF NOT SPECIFIED)
GitLinesDeleted = "${GIT_LINES_DELETED}"                    # Lines deleted since the previous commit (DERIVED IF NOT SPECIFIED)
GitLinesTotal = "${GIT_LINES_TOTAL}"                        # Total line count for the branch (DERIVED IF NOT SPECIFIED)
GitOrg = "${GIT_ORG}"                                       # Orgranization for the repo (DERIVED IF NOT SPECIFIED)
GitRepo = "${GIT_REPO}"                                     # Git repo that triggered the CI job (DERIVED IF NOT SPECIFIED)
GitRepoProject = "${GIT_REPO_PROJECT}"                      # Project name part of the repository url (DERIVED IF NOT SPECIFIED)
GitTag = "${GIT_TAG)"                                       # Git tag in the git repo (DERIVED IF NOT SPECIFIED)
GitTotalCommittersCnt = "${GIT_TOTAL_COMMITTERS_CNT}"       # Total committers working on this repo
GitUrl = "${GIT_URL}"                                       # Full url to the git repo (DERIVED IF NOT SPECIFIED)
License = ""                                                # License file location in the Git Repo (DERIVED IF NOT SPECIFIED)
operator = ""                                               # Operator name
Readme = ""                                                 # Readme file location in the Git Repo (DERIVED IF NOT SPECIFIED)
ServiceOwner = ""                                           # Owner of the Service
ServiceOwnerEmail = ""                                      # Email for the Owner of the Service
ServiceOwnerPhone = ""                                      # Phone number for the Owner of the Service
Swagger = ""                                                # Swagger/OpenApi file location in the Git Repo (DERIVED IF NOT SPECIFIED)
  • assign - assigns a Component Version to an Application Version Usage: --dhurl --dhuser --dhpass --compname --compvariant (optional) --compversion (optional) --appname --appversion (optional)

  • kv - assigns the key/values pairs to the Component Version Usage: --dhurl --dhuser --dhpass --compname --compvariant (optional) --compversion (optional) --kvconfig

  • envscript - creates a bash file from the Component toml file Usage: --envvars --envvars_sh

  • export - exports a Domain including all objects to stdout Usage: --dhurl --dhuser --dhpass --from_dom

  • import - imports the export file into the new Domain Usage: --dhurl --dhuser --dhpass --from_dom --to_dom

Parameter Usage
ParameterDescriptions
appautoincApplication Auto Increment Version
appnameApplication Name
appversionApplication Version
certCustomer SSL Certificate File
changerequestChange Request for Component, use multiple time for each Change Request Id
cluster_jsonjson from kubectl get deploy -n default -o json
compattrComponent attributes, use multiple time for each attr
compautoincComponent auto increment version
compnameComponent Name
compvariantComponent Variant
compversionComponent Version
consumesjson file that lists the endpoints the Component consumes. [ {"verb", "get", "path": "/weather"}]
crdatasourceChange Request Data Source for the Component
deploydataThe json file that contains the Application, Environment and log details
deploydatasaveName of the json file to save the new Component and Application Versions names to
deployenvDeployment Environment
deppkgFile name for the Safety, CycloneDx, SPDX json scan data, use multiple time for each file. Parameter format is: @ where type=safety, cyclonedx, spdx
dhpassOrtelius Password
dhurlOrtelius Url
dhuserOrtleius User
dockerdocker Kind of the Component item
envsEnvironments to Associate Application Version to, use multiple time for each env
envvars_shEnvironment Variables Output shell file
envvarsComponent TOML file
filefile Kind of the Component item
from_domainMove from Domain
fromdomFrom Domain
importfileFile to Import
kvconfigDirectory containing the json and properties file
logdeploymentRecords a deployment by a external program
msbranchNew microservice branch being added to the cluster
msnameNew microservice being added to the cluster
providesjson file that lists the Endpoints the Component provides. [ {"verb", "get", "path": "/checkout"}]
rspResponse File for Parameters, ie component.toml
taskTask to use for move
todomTo Domain

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc