Skip to content

Commit ab45f57

Browse files
committed
Update krakend organization
Signed-off-by: Albert Lombarte <[email protected]>
1 parent 2c38571 commit ab45f57

File tree

4 files changed

+30
-29
lines changed

4 files changed

+30
-29
lines changed

krakend/content.md

Lines changed: 27 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -2,37 +2,35 @@
22

33
# What is KrakenD?
44

5-
[KrakenD](https://www.krakend.io/) is a stateless, high-performance, enterprise-ready, open source API gateway written in Go. Its engine (formerly known as *KrakenD Framework*) is now a **Linux Foundation Project** codenamed [Lura Project](https://luraproject.org/). Lura is the only enterprise-grade API Gateway hosted in a neutral, open forum.
5+
[KrakenD](https://www.krakend.io/) is a stateless, high-performance, enterprise-ready, open-source API gateway written in Go. Its engine (formerly known as *KrakenD Framework*) is now a **Linux Foundation Project** codenamed [Lura Project](https://luraproject.org/). Lura is the only enterprise-grade API Gateway hosted in a neutral, open forum.
66

7-
KrakenD is very lightweight and simple to use as it only requires to write the configuration file, no Go knowledge is required. It offers connectivity to internal and external services, transformation and filtering of data, aggregation of multiple data sources (APIs, gRPC, queues and pub/sub, lambda, etc) simultaneously or in cascade, protects the access to your API, throughputs its usage, and integrates with a lot of third-parties.
7+
KrakenD is lightweight and straightforward as it only requires writing the configuration file. No Go knowledge is required. It offers connectivity to internal and external services, transformation and filtering of data, aggregation of multiple data sources (APIs, gRPC, queues and pub/sub, lambda, etc) simultaneously or in cascade, protects the access to your API, throughputs its usage, and integrates with a lot of third-parties.
88

9-
All features are designed to offer awesome performance and infinite scalability.
9+
All features are designed to offer extraordinary performance and infinite scalability.
1010

1111
## How to use this image
12-
KrakenD only needs a single configuration file to create an API Gateway, although you can have a complex setup reflecting your organization structure. The configuration file(s) can live anywhere in the container but the default location is `/etc/krakend`.
12+
KrakenD only needs a single configuration file to create an API Gateway, although you can have a complex setup reflecting your organization structure. The configuration file(s) can live anywhere in the container, but the default location is `/etc/krakend`.
1313

14-
To use the image, `COPY` your `krakend.json` file inside the container, or mount it using a volume. The configuration is checked only once during the startup and never used again. Don't have a config file yet? Generate it with the [KrakenD Designer UI](https://designer.krakend.io).
14+
To use the image, `COPY` your `krakend.json` file inside the container or mount it using a volume. The configuration is checked only once during the startup and never used again. Don't have a config file yet? Generate it with the [KrakenD Designer UI](https://designer.krakend.io).
1515

1616
⚠️ **NOTICE**: KrakenD does not use live reload when your configuration changes. Restart the container.
1717

1818
### Quick start
1919
You can start an empty gateway with a health check with the following commands:
2020

2121
```console
22-
$ echo '{ "version": 2 }' > krakend.json
22+
$ echo '{ "version": 3 }' > krakend.json
2323
$ docker run -d -p 8080:8080 -v "$PWD:/etc/krakend/" %%IMAGE%%
2424
...
2525
$ curl http://localhost:8080/__health
26-
{"status":"ok"}
26+
{"agents":{},"now":"2022-11-25 14:35:55.552591448 +0000 UTC m=+26.856583003","status":"ok"}
2727
```
2828

29-
30-
3129
### More Examples
32-
The following are several examples of running KrakenD. By default the command `run` is executed, but you can pass
30+
The following are several examples of running KrakenD. By default, the command `run` is executed, but you can pass
3331
other commands and flags at the end of the run command.
3432

35-
The configuration files are taken from current directory (`$PWD`). All examples expect to find at least the file `krakend.json`.
33+
The configuration files are taken from the current directory (`$PWD`). Therefore, all examples expect to find at least the file `krakend.json`.
3634

3735
#### Run with the debug enabled (flag `-d`):
3836
This flag is **SAFE to use in production**. It's meant to enable KrakenD as a fake backend itself by enabling a [`/__debug` endpoint](https://www.krakend.io/docs/endpoints/debug-endpoint/)
@@ -49,12 +47,12 @@ See the [check command](https://www.krakend.io/docs/commands/check/)
4947
```
5048
#### Show the help:
5149

52-
docker run -it -p 8080:8080 -v $PWD:/etc/krakend/ %%IMAGE%% --help
50+
docker run -it -p 8080:8080 -v $PWD:/etc/krakend/ %%IMAGE%% help
5351

5452

5553
### Building your custom KrakenD image
5654

57-
Most production deployments will not want to rely on mounting a volume for the container, but to use their own image based on `%%IMAGE%%`:
55+
Most production deployments will not want to rely on mounting a volume for the container but to use their image based on `%%IMAGE%%`:
5856

5957
Your `Dockerfile` could look like this:
6058

@@ -68,11 +66,10 @@ COPY krakend.json /etc/krakend/krakend.json
6866
RUN krakend check -d -t -c /etc/krakend/krakend.json
6967
```
7068

71-
If you want to manage your KrakenD configuration using multiple files and folders, reusing templates and distributing the configuration amongst your teams, you can use the [flexible configuration (FC)](https://www.krakend.io/docs/configuration/flexible-config/). The following `Dockerfile` combines FC, the `krakend check` command, and a 2-step build.
69+
If you want to manage your KrakenD configuration using multiple files and folders, reusing templates, and distributing the configuration amongst your teams, you can use the [flexible configuration (FC)](https://www.krakend.io/docs/configuration/flexible-config/). The following `Dockerfile` combines FC, the `krakend check` command, and a 2-step build.
7270

7371
```Dockerfile
7472
FROM %%IMAGE%%:<version> as builder
75-
ARG ENV=prod
7673

7774
COPY krakend.tmpl .
7875
COPY config .
@@ -81,26 +78,23 @@ COPY config .
8178
RUN FC_ENABLE=1 \
8279
FC_OUT=/tmp/krakend.json \
8380
FC_PARTIALS="/etc/krakend/partials" \
84-
FC_SETTINGS="/etc/krakend/settings/$ENV" \
81+
FC_SETTINGS="/etc/krakend/settings" \
8582
FC_TEMPLATES="/etc/krakend/templates" \
8683
krakend check -d -t -c krakend.tmpl
8784

8885
# Copy the output file only and discard any other files
8986
FROM %%IMAGE%%:<version>
90-
COPY --from=builder --chown=krakend /tmp/krakend.json .
87+
COPY --from=builder /tmp/krakend.json .
9188
```
92-
Then build with `docker build --build-arg ENV=prod -t my_krakend .`
89+
Then build with `docker build -t my_krakend .`
9390

9491
The configuration above assumes you have a folder structure like the following:
9592
```
9693
.
9794
├── config
9895
│ ├── partials
9996
│ ├── settings
100-
│ │ ├── prod
101-
│ │ │ └── env.json
102-
│ │ └── test
103-
│ │ └── env.json
97+
│ │ └── env.json
10498
│ └── templates
10599
│ └── some.tmpl
106100
├── Dockerfile
@@ -116,20 +110,20 @@ services:
116110
krakend:
117111
image: %%IMAGE%%:<version>
118112
ports:
119-
- "8080:8080"
113+
- "8080:8080"
120114
volumes:
121115
- ./:/etc/krakend
122116
```
123117
124-
And another one that uses flexible configuration and a custom template filename (`my_krakend.tmpl`) on each start:
118+
And another one that uses the flexible configuration and a custom template filename (`my_krakend.tmpl`) on each start:
125119

126120
```yaml
127121
version: "3"
128122
services:
129123
krakend:
130124
image: %%IMAGE%%:<version>
131125
ports:
132-
- "8080:8080"
126+
- "8080:8080"
133127
volumes:
134128
- ./:/etc/krakend
135129
environment:
@@ -139,5 +133,12 @@ services:
139133
- FC_SETTINGS="/etc/krakend/config/settings/prod"
140134
- FC_TEMPLATES="/etc/krakend/config/templates"
141135
command:
142-
command: ["run", "-c", "krakend.tmpl", "-d"]
136+
command: ["krakend", "run", "-c", "krakend.tmpl", "-d"]
143137
```
138+
### Container permissions and commands
139+
All `krakend` commands are executed as `krakend` user (uid=1000) through `su-exec`, and the rest of the commands (e.g., `sh`) are executed as root.
140+
141+
You can directly use sub-commands of `krakend` like `run`, `help`, `version`, `check`, `check-plugin` or `validate` as the entrypoint will add the `krakend` command automatically. For example, the following lines are equivalent:
142+
143+
docker run -it -p 8080:8080 -v $PWD:/etc/krakend/ %%IMAGE%% help
144+
docker run -it -p 8080:8080 -v $PWD:/etc/krakend/ %%IMAGE%% krakend help

krakend/get-help.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
[documentation](https://www.krakend.io/docs/overview/introduction/), [community support](https://groups.google.com/a/krakend.io/g/community), [open an issue](https://github.com/devopsfaith/krakend-ce/issues), [other support channels](https://www.krakend.io/support/)
1+
[documentation](https://www.krakend.io/docs/overview/introduction/), [community support](https://groups.google.com/a/krakend.io/g/community), [open an issue](https://github.com/krakendio/krakend-ce/issues), [other support channels](https://www.krakend.io/support/)

krakend/github-repo

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
https://github.com/devopsfaith/krakend-ce
1+
https://github.com/krakendio/krakend-ce

krakend/license.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
View [license information](https://github.com/devopsfaith/krakend-ce/blob/master/LICENSE) for the software contained in this image.
1+
View [license information](https://github.com/krakendio/krakend-ce/blob/master/LICENSE) for the software contained in this image.

0 commit comments

Comments
 (0)