Hello,
A few weeks ago I was transferring integration flow to a production system. I was surprised that I could not import iflow with the same name and after moving the iflow I had to manually recreate the configuration of the new version of the iflow. At the same time, I was learning the go programming language. I thought it would be good to combine learning with something useful.
I would like to introduce the Cloud Integration CLI for manage and query integration artifacts of design time and runtime.
The tool is written in go language. Go is cross-platform, which means that the tool will work on different operating systems, including Windows, Linux, and macOS.
Personally, I use this tool to transport iflows between systems (cig flow transport), update flow configurations (cig flow describe-configs / cig flow update-configs) and update resources, such as groovy script (cig resource update).
The project repository is available at:
https://github.com/tobiaszgithub/cig
Executable files for the various operating systems are available at:
https://github.com/tobiaszgithub/cig/releases
The first thing after downloading the tool is to create a configuration file:
To generate the configuration file, you can use the generate-config command, please check the following screenshot:
generating configuration file
Update the data in the file and leave the file where it was generated or move it to a directory:
USER_HOME_DIRECTORY/.cig
Multiple tenants can be added to the configuration file. The value from the "activeTenantKey" field will be used as the default tenant for the commands being executed. I tested the tool in the Neo and Cloud Foundry environments. In the case of Neo, 'basic' authorization type can be used and in the case of Cloud Foundry you have to use 'oauth' authorization type.
How to generate oauth credentials in the cloud foundry can be found here:
https://blogs.sap.com/2021/07/13/using-cloud-integration-apis-with-tools-on-cloud-foundry-creating-a...
Some screenshot of the running application:
Below I attach a description to the current commands (application version v0.1.1)
CLI for Cloud Integration.
Using this tool it is possible to manage and query integration artifacts of design time and runtime.
Usage:
cig [command]
Available Commands:
- completion - Generate the autocompletion script for the specified shell
- flow - Command related to the processing of an integration flow
- generate-config - Generate config file
- help - Help about any command
- package - Command related to the processing of integration packages
- resource - Command related to the processing of resources of an integration flow
Flags:
-h, --help help for cig
-t, --tenant-key string Tenant key from configuration file
Use "cig [command] --help" for more information about a command.
cig flow
Command related to the processing of an integration flow.
Usage:
cig flow [command]
Available Commands:
- copy - Copy an integration flow
- create - Create or upload an integration flow
- deploy - Deploy an integration flow
- describe-configs - Get configurations of an integration flow by Id and version
- download - Download an integration flow as zip file
- inspect - Get integration flow by id and version
- transport - Transport an integration flow between systems
- update - Update an integration flow
- update-configs - Update configuration parameters of an integration flow
Flags:
-h, --help help for flow
Global Flags:
-t, --tenant-key string Tenant key from configuration file
Use "cig flow [command] --help" for more information about a command.
cig generate-config
Generate configuration file. This file is nessesary for the operation of the cig tool. Configuration file should be placed in working directory or userhome/.cig/ directory
Usage:
cig generate-config [flags]
Flags:
-h, --help help for generate-config
-o, --output-file string The output file with empty configuration parameters that will be created (default "config.json")
Global Flags:
-t, --tenant-key string Tenant key from configuration file
cig package
Command related to the processing of integration packages
Usage:
cig package [flags]
cig package [command]
Aliases:
package, ls, p
Available Commands:
- download - Download integration package by ID
- inspect - Get integration package by ID
- ls - Get all integration packages as list or get all integration flow of the package
Flags:
-h, --help help for package
Global Flags:
-t, --tenant-key string Tenant key from configuration file
cig resource
Command related to the processing of resources of an integration flow
Usage:
cig resource [command]
Available Commands:
- update - Update a resource of an integration flow
Flags:
-h, --help help for resource
Global Flags:
-t, --tenant-key string Tenant key from configuration file
Use "cig resource [command] --help" for more information about a command.