The wikis are now using the new authentication system.
If you did not migrate your account yet, visit https://idp-portal-info.suse.com/

SDB:Install Ritchie

Jump to: navigation, search


oneAPI.
Ritchie CLI is an open source product that allows you to create, store and share any kind of automations, executing them through command lines, to run operations or start workflows.

Formulas

In Ritchie's context, a formula is a script that can be executed automatically or interactively through a command line.

Adapting an existing script to Ritchie structure allows you to run it locally or through Docker, and to share it on a Github or Gitlab repository.

formulas.

Usability

As formulas are executed after running command lines on the terminal, the user might need to inform input parameters.

Those input parameters can be informed in different ways:

  • After running the command on the terminal (via prompt)
  • When typing the command on the terminal (via stdin)
  • During the execution of the formula (if coded using prompt) formulas.

formulas.

Key Features

  • Multi Platform Support : Works on Linux, MacOS and Windows
  • Multi Languages Support : Formulas can be coded in any programming language
  • Centralized Tools : Create and customize the CLI to centralize your tools, all in one place !
  • Versatility : You can automate anything in any language… so everyone can use it !

"Hello World" formula

You will find in this section how to run a "hello-world" formula.

Hello World

After you finished the previous steps -installation and initialization - to access the hello-world formula to test Ritchie, you'll need to add the ritchie-formulas-demo repository locally.

To do so, you can use the rit add repo command, or execute the command line below:


echo '{"provider":"Github", "name":"demo", "version":"2.0.0", "url": \
"https://github.com/ZupIT/ritchie-formulas-demo", "token": null, "priority":1}' | \
rit add repo --stdin

You can check which repositories you're using with therit list repo command.


Now that you have added the demo repository, you can execute this tutorial commands.

On Ritchie, you have 4 possibilities to run a formula:

  • Using Prompt
  • Using Prompt and Docker
  • Using Stdin
  • Using Stdin and Docker

To do so, type the following commands lines:

With Prompt

As this formula has been coded using Golang, it is necessary to have Golang installed on your computer to run it locally.

rit demo hello-world

Installing : Zypper repository instructions

For opensuse installation use the commands below:

Add repository and install manually

For openSUSE Tumbleweed run the following as root:

zypper addrepo https://download.opensuse.org/repositories/devel:tools/openSUSE_Tumbleweed/devel:tools.repo
zypper refresh
zypper install ritchie-cli

For openSUSE Leap 15.2 run the following as root:

zypper addrepo https://download.opensuse.org/repositories/devel:tools/openSUSE_Leap_15.2/devel:tools.repo
zypper refresh
zypper install ritchie-cli

For openSUSE Leap 15.1 run the following as root:

zypper addrepo https://download.opensuse.org/repositories/devel:tools/openSUSE_Leap_15.1/devel:tools.repo
zypper refresh
zypper install ritchie-cli

For openSUSE Factory zSystems run the following as root:

zypper addrepo https://download.opensuse.org/repositories/devel:tools/openSUSE_Factory_zSystems/devel:tools.repo
zypper refresh
zypper install ritchie-cli

For openSUSE Factory PowerPC run the following as root:

zypper addrepo https://download.opensuse.org/repositories/devel:tools/openSUSE_Factory_PowerPC/devel:tools.repo
zypper refresh
zypper install ritchie-cli

For openSUSE Factory ARM run the following as root:

zypper addrepo https://download.opensuse.org/repositories/devel:tools/openSUSE_Factory_ARM/devel:tools.repo
zypper refresh
zypper install ritchie-cli

This text was built by openSUSE member Alessandro de Oliveira Faria based on Ritchie tutorials.

See also