Abstract
Working with Adobe IO Command line interface
Some times we need to work with AEM as cloud without accessing the AEM AS Cloud environment directly.
So to work with Adobe I/O CLI we need to install Node JS first. Then follow through the steps.
Step 1: Install Adobe I/O
npm install -g @adobe/aio-cli
Step 2: Install Adobe I/O Cloud Manager Plugin
aio plugins:install @adobe/aio-cli-plugin-cloudmanager
Step 3: Update the plugins
aio plugins:update
Above diagram gives an overview on environment provisioning in AEM as cloud
Step 4: First List the organizations tagged
aio cloudmanager:org:list
Step 5: Then select the Organization from above list
aio cloudmanager:org:select [Your org id from above list]@AdobeOrg
Step 6: aio cloudmanager:list-programs
Step 7: Then set a program
aio config:set cloudmanager_programid [Your prog id from above list]
Step 8: List all environments
aio cloudmanager:list-environments
Now based on requirements, you can execute the commands. Some examples are given below,
To Download logs:
aio cloudmanager:download-logs [env id] author aemerror 1
To list log options
aio cloudmanager:environment:list-available-log-options [env id]
To list OSGi Environment varriables
aio cloudmanager:list-environment-variables [env id]
To List Pipelines
aio cloudmanager:program:list-pipelines
To list a specific pipeline status
aio cloudmanager:pipeline:list-executions [pipeline id]
OSGi Commands
-----------
To Set OSGI parameters
aio cloudmanager:set-environment-variables ENVIRONMENT_ID --variable MY_VAR1 "plaintext value" --secret MY_VAR2 "some secret value"
To List environment variables
aio cloudmanager:list-environment-variables ENVIRONMENT_ID
To Delete any variables.
aio cloudmanager:set-environment-variables ENVIRONMENT_ID --delete MY_VAR1 MY_VAR2
Ref URL:
https://github.com/adobe/aio-cli-plugin-cloudmanager#aio-cloudmanagerenvironmentdownload-logs-environmentid-service-name-days
https://github.com/adobe/aio-cli-plugin-auth#aio-authlogin
https://github.com/adobe/aio-cli
Read Full Blog
Q&A
Please use this thread to ask the related questions.
Kautuk Sahni