Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • list-item
    • Returns the list of scheduling objects from JOC Cockpit's Git repository. The list will be returned in JSON format.
    • The command is used alternatively
      • with the --path and --type options to specify an individual object. One of the following object types has to be specified:
        • Deployable object types: WORKFLOW, FILEORDERSOURCE, JOBRESOURCE, NOTICEBOARD, LOCK
        • Releasable object types: INCLUDESCRIPT, SCHEDULE, WORKINGDAYSCALENDAR, NONWORKINGDAYSCALENDAR, JOBTEMPLATE, REPORT
      • with the --folder option to include all objects in the related folder to be returned. The --recursive switch can be used to process sub-folders recursively.
  • store-item
    • Stores scheduling objects of JOC Cockpit's inventory to JOC Cockpit's Git repository.
    • The following options and switches can be used to limit objects that should be stored:
      • The --path and --type options are used to store individual objects JOC Cockpit's Git repository.
      • The --folder option and optionally --recursive switch are used to store objects from a folder hierarchy to JOC Cockpit's Git repository.
      • The --change option is used to store objects and dependencies of a change to JOC Cockpit's Git repository.
        • The --folder option can be specified to limit objects to the related folder in JOC Cockpit's Git repository. Without this option the objects of the change will be stored to related JOC Cockpit Git repositories corresponding to their folders.
        • The --no-referencing option can be specified to exclude objects that hold references to one of the objects included with the change.
        • The --no-references option can be specified to exclude objects included with that are referenced by objects in the change that hold references to other objects.
    • Later commit and push commands will apply changes resulting from updated objects in JOC Cockpit's Git repository.
  • update-item
    • Updates the JOC Cockpit inventory from scheduling objects available in JOC Cockpit's Git repository.
    • The --path and --type options are used to update individual objects from JOC Cockpit's Git repository to the inventory.
    • The --folder option and optionally --recursive switch are used to update objects from a folder hierarchy in JOC Cockpit's Git repository to the inventory.
    • The --change option is used to update objects and dependencies of a change from JOC Cockpit's Git repository. For applicable options and switches see store-item command.
  • delete-item
    • Deletes scheduling objects from JOC Cockpit's Git repository. The operation does not affect existence of objects in JOC Cockpit's inventory. Later commit and push commands will apply changes. Users should first use the command to delete objects from JOC Cockpit's Git repository, then delete objects from the inventory.

    • The --path and --type options are used to delete individual objects from JOC Cockpit's Git repository.
    • The --folder option and optionally --recursive switch are used to delete objects from a folder hierarchy in JOC Cockpit's Git repository.
    • The --change option is used to delete objects and dependencies of a change from JOC Cockpit's Git repository. For applicable options and switches see store-item command.
  • clone
    • Clones a remote Git repository to a JOC Cockpit Git repository.
    • The command is used with the --remote-url option to identify the remote Git repository. Frequently the syntax git@<git-server>:<owner>/<repository> is used, for example: git@github.com:sos-berlin/js7-demo-inventory-rollout-test
  • checkout
    • A specific branch from the remote Git repository is checked out using the --branch or --tag options to identify the branch.
  • add
    • Adds changes to JOC Cockpit's Git repository.
  • commit
    • Commits changes to JOC Cockpit's Git repository.
    • The command is used with the --folder option to specify the inventory folder that is mapped to the Git repository. The --message option is used to specify a message that  typically becomes visible when displaying commits to a repository in a Git Server.
    • The command returns the commit hash created by Git when committing changes.
  • push
    • Pushes objects from JOC Cockpit's Git repository to the remote Git repository.
    • The command is used with the --folder option to specify the inventory folder that is mapped to the Git repository.
  • pull
    • Pulls objects from the remote Git repository to JOC Cockpit's Git repository. Objects in JOC Cockpit's Git repository will be removed, added or updated.
    • The command is used with the --folder option to specify the inventory folder that is mapped to the Git repository.
  • get-credentials
    • Reads Git credentials from the user's profile in JOC Cockpit.
    • If credentials for more than one Git Server are available then they will be returned.
  • store-credentials
    • Stores Git credentials to the user's profile in JOC Cockpit.
    • The command is used with the --server option to specify the Git Server for which credentials will be stored.
    • For authentication with Git one of the --user-password, --user-access-token or --user-private-key options must be used.
      • The location of a private key file must be specified from an absolute path that is readable for the JOC Cockpit service.
      • Users have to store the private key file to the related location.
  • delete-credentials
    • Deletes Git credentials from the user's profile in JOC Cockpit.
    • The command is used with the --server option to specify the Git Server for which credentials will be deleted.

...

  • --url
  • --user
    • Specifies the user account for login to JOC Cockpit. If JS7 - Identity Services are available for Client authentication certificates that are specified with the --client-cert and --client-key options then their common name (CN) attribute has to match the user account.
    • If a user account is specified then a password can be specified using the --password option or interactive keyboard input can be prompted using the -p switch.
  • --password
    • Specifies the password used for the account specified with the --user option for login to JOC Cockpit.
    • Password input from the command line is considered insecure.
      • Consider use of the -p switch offering a secure option for interactive keyboard input.
      • Consider use of the encrypt command to encrypt a password: ./deploy-controller.sh encrypt --in=root --cert=encrypt.crt.
        • The encryption result will include the prefix enc: followed by the encrypted symmetric key, initialization vector and encrypted secret separated by space.
        • If an encrypted password is specified, then it will be decrypted using the Private Key file: ./deploy-controller.sh <command> --password="enc:BF8J8KP7TPlxy..." --key=encrypt.key.
  • --ca-cert
    • Specifies the path to a file in PEM format that holds the Root CA Certificate and optionally Intermediate CA Certificates to verify HTTPS connections to JOC Cockpit.
  • --client-cert
    • Specifies the path to a file in PEM format that holds the Client Certificate if HTTPS mutual authentication is used..
  • --client-key
    • Specifies the path to a file in PEM format that holds the Client Private Key if HTTPS mutual authentication is used..
  • --timeout
    • Specifies the maximum duration for requests to the JS7 REST Web Service. Default: 60 seconds.
  • --controller-id
    • Specifies the identification of the Controller.
  • --folder
    • When used with commands, specifies the JOC Cockpit's inventory folder to which the command is applied.
      • For use with the update-item, store-item and delete-item commands more than one folder can be specified separated by comma, for example: --folder=/TestRepo/Accounting,/TestRepo/Reporting
    • The --recursive switch is used If sub-folders should be processed recursively.
  • --path
    • When used with the store-item , update-item and delete-item commands, specifies the path of an object including folder, sub-folders and object name.
    • Use of the --path option requires specification of the --type option to determine the object type.
    • The option is used alternatively to specification of a folder using the --folder option.
  • --type
    • When used with the store-item , update-item and delete-item commands and the --path option, specifies the type of object that should be processed:
      • Deployable object types: WORKFLOW, FILEORDERSOURCE, JOBRESOURCE, NOTICEBOARD, LOCK
      • Releasable object types: INCLUDESCRIPT, SCHEDULE, WORKINGDAYSCALENDAR, NONWORKINGDAYSCALENDAR, JOBTEMPLATE, REPORT
    • Use of the option is required if the --path option is used.
  • --change
    • In JOC Cockpit users can assign inventory objects to a change. The identification of the change can be specified when using the --store-item, update-item orand delete-item commands to store, to update or to delete objects and dependencies included with the change.
    • Commands related to a change by default include referencing objects and referenced objects. See --no-referencing and --no-references switches to exclude such objects.
  • --branch
    • When used with the checkout command specifies the name of the Git repository branch to be checked out.
  • --tag
    • When used with the checkout command specifies the tag that identifies the Git repository branch to be checked out. If more than one tag is used, they are separted by comma, for example: --tag=prod,v1.12
  • --message
    • When used with the commit command, specifies the message that explains the purpose of the commit operation.
  • --server
    • When used with the store-credentials and delete-credentials commands, specifies the hostname of the Git Server.
    • Git credentials are stored on a per Git Server basis.
  • --user-account
    • When used with the store-credentials command, specifies the account used for authentication with the Git Server.
  • --user-name
    • When used with the store-credentials command, specifies the user name used for authentication with the Git Server.
  • --user-mail
    • When used with the store-credentials command, specifies the e-mail address used for authentication with the Git Server.
  • --user-password
    • When used with the store-credentials command, specifies the password used for authentication with the Git Server.
    • Password input from the command line is considered insecure.
      • Consider use of the -u switch that asks for interactive keyboard input of the password.
      • The switch is used for secure interactive input as an alternative to use of the --user-password=<password> option.
    • Only one of --user-password, --user-access-token or --user-private-key options can be used.
  • --user-access-token
    • When used with the store-credentials command, specifies the access token used for authentication with the Git Server.
    • Only one of --user-password, --user-access-token or --user-private-key options can be used.
  • --user-private-key
    • When used with the store-credentials command, specifies the path to a private key file used for authentication with the Git Server.
      • The location of a private key file must be specified from an absolute path that is readable for the JOC Cockpit service.
      • Users have to store the private key file to the related location.
    • Only one of --user-password, --user-access-token or --user-private-key options can be used.
  • --remote-url
    • When used with the clone command, specifies the URL of the repository to be cloned.
    • Frequently the syntax git@<git-server>:<owner>/<repository> is used, for example: git@github.com:sos-berlin/js7-demo-inventory-rollout-test
  • --audit-message
    • Specifies a message that is made available to the Audit Log.
    • Specification of Audit Log messages can be enforced on a per user basis and for a JS7 environment.
  • --audit-time-spent
    • Specifies the time spent to perform an operation which is added to the Audit Log.
    • The option can be specified if the --audit-message option is used.
  • --audit-link
    • Specifies a link (URL) which is added to the Audit Log.
    • The option can be specified if the --audit-message option is used.
  • --log-dir
    • If a log directory is specified then the script will log information about processing steps to a log file in this directory.
    • File names are created according to the pattern: deploy-controller.<yyyy>-<MM>-<dd>T<hh>-<mm>-<ss>.log
    • For example: deploy-controller.2022-03-19T20-50-45.log

...

  • -h | --help
    • Displays usage.
  • -v | --verbose
    • Displays verbose log output that includes requests and responses with the JS7 REST Web Service.
    • When used twice as with -v -v then curl verbose output will be displayed.
  • -p | --password
    • Asks the user for interactive keyboard input of the password used for the account specified with the --user option..
    • The switch is used for secure interactive input as an alternative to use of the option --password=<password>.
  • -i | --no-referencing
    • The switch is specified to exclude objects that hold references to objects included with the change indicated with the --change option.
  • -s | --no-references
    • The switch is specified to exclude objects that are referenced by objects included with the change indicated with the --change option.
  • -l | --local
    • Specifies a JOC Cockpit Git repository of type "local" to be used:
      • Repositories of type "local" hold object types that are specific for a scheduling environment and should not be deployed using Git and are stored to a separate repository.
        • Location: <jetty-base>/resources/joc/repositories/local
      • Repositories of type "rollout" hold object types that should be deployed using Git.
        • Location: <jetty-base>/resources/joc/repositories/rollout
      • Which object types make it for which repository type can be specified from settings, see JS7 - Inventory Git Integration.
    • If the switch is not specified, then the repository type "rollout" is assumed.
  • -r | --recursive
    • When used with the --folder option, specifies that sub-folders should be processed recursively.
  • -u | --user-password
    • Asks the user for interactive keyboard input of the password used for authentication with a Git Server when using the store-credentials command.
    • The switch is used for secure interactive input as an alternative to use of the --user-password=<password> option.
  • --no-referencing
    • The switch is specified to exclude objects that hold references to objects included with the change indicated with the --change option.
  • --no-references
    • The switch is specified to exclude objects that are referenced by objects included with the change indicated with the --change option.
  • --show-logs
    • Displays the log output created by the script if the --log-dir option is used.
  • --make-dirs
    • If directories are missing that are indicated with the --log-dir option then they will be created.

...