Page History
...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
# common options for connection to JS7 REST API request_options=(--url=http://localhost:4446 --user=root --password=root --controller-id=controller) # post notice for current daily plan date ./operate-workflow.sh post-notice "${request_options[@]}" \ --notice-board=ap3jobs # post notice for specific daily plan date and lifetime ./operate-workflow.sh post-notice "${request_options[@]}" \ --notice-board=ap3jobs --notice-id=2024-08-26 --notice-lifetime=6h # reading notices from notice board ./operate-workflow.sh get-notice "${request_options[@]}" \ --notice-board=ap3jobs # reading specific notice from notice board ./operate-workflow.sh get-notice "${request_options[@]}" \ --notice-board=ap3jobs --notice-id=2024-08-26 # reading notices by folder ./operate-workflow.sh get-notice "${request_options[@]}" \ --folder=/ap --recursive # delete notices from notice board for current daily plan date ./operate-workflow.sh delete-notice "${request_options[@]}" \ --notice-board=ap3jobs # delete specific notices from notice board using notice identifiers ./operate-workflow.sh delete-notice "${request_options[@]}" \ --notice-board=ap3jobs --notice-id=2024-08-25,2024-08-26 # delete notices by folder ./operate-workflow.sh delete-notice "${request_options[@]}" \ --folder=/ap --recursive |
...
Using encrypted Password
- Secrets can be encrypted and decrypted as explaind with JS7 - Encryption and Decryption.
- Encryption/decryption require related Java libraries that are available from the
./lib
sub-directory. - For creation of a Private Key and Certificate see JS7 - How to create X.509 Encryption Keys.
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
# create Private Key openssl ecparam -name secp384r1 -genkey -noout -out encrypt.key # create Certificate Signing Request, adjust the subject to your needs openssl req -new -sha512 -nodes -key encrypt.key -out encrypt.csr -subj "/C=DE/ST=Berlin/L=Berlin/O=SOS/OU=IT/CN=Encrypt" # create Certificate, adjust the validity period to your needs openssl x509 -req -sha512 -days 1825 -signkey encrypt.key -in encrypt.csr -out encrypt.crt -extfile <(printf "keyUsage=critical,keyEncipherment,keyAgreement\n") # encrypt athe secretpassword such as a password "root" using the Certificate, the encryption result will be returned and will look like: enc:BEXbHYa... MY_JS7_PASSWORD=$(./operate-workflow.sh encrypt --in="root" --cert=encrypt.crt) # store optionsthe forenvironment connectionvariable to your the JS7 REST API can specifyprofile ($HOME/.bash_profile or similar) to make the encryptionencrypted result password available to the shell # export MY_JS7_PASSWORD=enc:BEXbHYa... # options for connection to the JS7 REST API can specify the encryption result as password and the Private Key for decryption request_options=(--url=http://localhost:4446 --user=root --password="enc:BEXbHYa...$MY_JS7_PASSWORD" --key=encrypt.key --controller-id=controller) # for example, when adding an ad hoc order the Private Key is used to decrypt the password for access to the REST API on-the-fly ./operate-workflow.sh add-order "${request_options[@]}" --workflow=ap3jobs # decrypt an encrypted secret using the Private Key ./operate-workflow.sh decrypt --in="enc:BEXbHYa..." --key=encrypt.key |
Resources
- API
- Workflow Deployment Operations
- Workflow Status Operations
- Controller Deployment Operations
- Controller Status Operations
- Identity Service Deployment Operations
- JOC Cockpit Status Operations
...
Overview
Content Tools