News KrakenD Enterprise v2.6 released with OpenTelemetry, FIPS-140, gRPC server and more

Enterprise Documentation

Recent changes

Running KrakenD

Document updated on Jun 6, 2021

From an operations point of view, KrakenD is very simple to use. It only requires you to pass the path to the configuration file(s) which define behaviors and endpoints.

Make sure KrakenD can find a krakend.json and a LICENSE file. You can create an initial krakend.json with the following content:

Create a minimal configuration file 
$echo '{ "version": 2 }' > krakend.json

And then run the container (AWS example):

Running KrakenD using the Docker container 
$docker run -p 8080:8080 -v "$PWD:/etc/krakend/" krakend/krakend-ee:2.6.1 run --config /etc/krakend/krakend.json --accept-eula

Basic usage

  1. Generate a configuration file with your endpoints definition. The easier way to generate it is using the designer
  2. Check the syntax of your krakend.json is good
    Syntax checking 
    $krakend check -t --config krakend.json --debug
    	
  3. Run KrakenD
    Start the server 
    $krakend run -c krakend.json -d
    	

The flag -c is the short version of --config and -d the short version of --debug which allows you to find problems easily.

Using KrakenD

To start KrakenD make sure to provide the path to the binary or add it to the PATH if using the non-Docker installation. KrakenD has the following options:

The krakend command 
$krakend

╓▄█                          ▄▄▌                               ╓██████▄µ
▐███  ▄███╨▐███▄██H╗██████▄  ║██▌ ,▄███╨ ▄██████▄  ▓██▌█████▄  ███▀╙╙▀▀███╕
▐███▄███▀  ▐█████▀"╙▀▀"╙▀███ ║███▄███┘  ███▀""▀███ ████▀╙▀███H ███     ╙███
▐██████▌   ▐███⌐  ,▄████████M║██████▄  ║██████████M███▌   ███H ███     ,███
▐███╨▀███µ ▐███   ███▌  ,███M║███╙▀███  ███▄```▄▄` ███▌   ███H ███,,,╓▄███▀
▐███  ╙███▄▐███   ╙█████████M║██▌  ╙███▄`▀███████╨ ███▌   ███H █████████▀
                     ``                     `'`

Version: v1.3.0

The API Gateway builder

Usage:
  krakend [command]

Available Commands:
  check       Validates that the configuration file is valid.
  generate    Generates static content for several functionalities. See subcommands.
  help        Help about any command
  run         Run the KrakenD server.

Flags:
  -c, --config string   Path to the configuration filename
  -d, --debug           Enable the debug
  -h, --help            help for krakend

Use "krakend [command] --help" for more information about a command.

As you can see there are 3 different supported commands:

Scarf

Unresolved issues?

The documentation is only a piece of the help you can get! Whether you are looking for Open Source or Enterprise support, see more support channels that can help you.