SCREEN

In this guide, you will install Akamas CLI to connect to an Akamas server, such as the Akamas In-A-Sandbox (AIAS) environment to excute Akamas commands from on your own workstation.

What you will learn

What you will need

To get started, you only need the following:

Linux

To get Akamas CLI installed on Linux, you just need to run the following commands:

curl -o akamas_cli -O https://s3.us-east-2.amazonaws.com/akamas/cli/$(curl https://s3.us-east-2.amazonaws.com/akamas/cli/stable.txt)/linux_64/akamas
sudo mv akamas_cli /usr/local/bin/akamas
chmod 755 /usr/local/bin/akamas

Windows - Powershell

Instead, to get Akamas CLI installed on Windows, run the following command from the Powershell:

Invoke-WebRequest "https://s3.us-east-2.amazonaws.com/akamas/cli/$($(Invoke-WebRequest https://s3.us-east-2.amazonaws.com/akamas/cli/stable.txt | Select-Object -Expand Content) -replace '\n', '')/win_64/akamas.exe" -OutFile akamas.exe

Run the commands in the following sections by running .\akamas in the same folder. Otherwise, to invoke the akamas CLI from any folder, create an akamas folder (as an example C:\akamas) and move within it the akamas.exe file. Then, add an entry to the PATH system environment variable with value C:\akamas. Now, you can invoke the CLI from any folder, by running the akamas command. See the next sections for other examples.

Now the CLI can be used by running akamas. You can now verify whether you can access the Akamas server using the CLI by running the following commands from your terminal:

akamas --version

which should return something as

Akamas CLI, version 2.6.2

and

akamas --help

which should the following

Usage: akamas [OPTIONS] COMMAND [ARGS]...

  A command line interface for Akamas.

Options:
  --version  Show the version and exit.
  --help     Show this message and exit.

Commands:
  build      Build a resource.
  create     Create a resource
  delete     Delete a resource
  describe   Show details of a specific resource
  export     Export a resource
  finish     Terminate the execution of a resource
  import     Restore a resource
  init       Initializes resources and other entities
  install    Install a resource
  list       List resource instances
  log        Show Akamas logs
  login      Login into Akamas
  logout     Logout from Akamas
  set        Set a resource.
  start      Start an execution of a resource
  status     Show the status of Akamas services
  uninstall  Uninstall a resource
  update     Update a resource
  whoami     Show logged user, current workspace and configured api address

Type akamas init config and follow the wizard you will be presented with.

The following example features CLI configuration over https (suggested protocol):

Api address [http://localhost:8000]: https://<akamas server dns name>:8443
Workpace [default]: default
Verify SSL: [True]: True
Is external certificate CA required? [y/N]: N

You can now login, using akamas login and providing the credentials. Now you have the power of executing commands against the Akamas server.

Aa a next step you might want to use CLI commands to create Akamas artifacts and an optimization study Create your first optimization study!

© Akamas Spa 2018-present. Akamas and the Akamas logo are registered trademarks of Akamas Spa.