Skip to content

Commit

Permalink
docs(gh-page): update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
fhussonnois committed Sep 29, 2023
1 parent 034bdf5 commit 927d0c7
Show file tree
Hide file tree
Showing 15 changed files with 259 additions and 167 deletions.
2 changes: 1 addition & 1 deletion docs/content/en/docs/Community/_index.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: "Community"
linkTitle: "Community"
weight: 5
weight: 20
description: >
What does your user need to know to try your project?
---
Expand Down
2 changes: 1 addition & 1 deletion docs/content/en/docs/Concepts/_index.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: "Concepts"
linkTitle: "Concepts"
weight: 2
weight: 4
description: >
Learn the differents concepts used within Jikkou
---
Expand Down
2 changes: 1 addition & 1 deletion docs/content/en/docs/Developer Guide/_index.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: "Developer Guide"
linkTitle: "Developer Guide"
weight: 4
weight: 6
description: >
Learn how to use the Jikkou API
---
Expand Down
2 changes: 1 addition & 1 deletion docs/content/en/docs/Frequently Asked Questions/_index.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: "Frequently Asked Questions"
linkTitle: "Frequently Asked Questions"
weight: 6
weight: 10
description: >
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
---
title: "Installing Jikkou"
linkTitle: "Installing Jikkou"
weight: 2
title: "Install Jikkou"
linkTitle: "Install"
weight: 1
description: >
This guide shows how to install the Jikkou CLI.
This guide shows how to install the Jikkou CLI.
---

{{% pageinfo %}}
Expand All @@ -14,7 +14,7 @@ Jikkou can be installed either from source, or from releases.

### Releases

Every [`release`](https://github.com/streamthoughts/jikkou/releases) released versions of Jikkou is available:
Every [`release`](https://github.com/streamthoughts/jikkou/releases) released versions of Jikkou is available:

* As a zip/tar.gz package from [GitHub Releases](https://github.com/streamthoughts/jikkou/releases) (for Linux, MacOS)
* As a fatJar available from [Maven Central](https://repo.maven.apache.org/maven2/io/streamthoughts/jikkou/0.26.0/)
Expand Down Expand Up @@ -72,8 +72,9 @@ In addition to releases you can download or install development snapshots of Jik

### From Docker Hub

Docker images are built and push to [Docker Hub](https://hub.docker.com/r/streamthoughts/jikkou) from the latest `main` branch.
They are not official releases, and may not be stable.
Docker images are built and push to [Docker Hub](https://hub.docker.com/r/streamthoughts/jikkou) from the latest `main`
branch.
They are not official releases, and may not be stable.
However, they offer the opportunity to test the cutting edge features.

```bash
Expand All @@ -82,7 +83,8 @@ $ docker run -it streamthoughts/jikkou:main

### From Source (Linux, macOS)

Building Jikkou from source is slightly more work, but is the best way to go if you want to test the latest (pre-release) Jikkou version.
Building Jikkou from source is slightly more work, but is the best way to go if you want to test the latest (
pre-release) Jikkou version.

#### Prerequisites

Expand Down
12 changes: 0 additions & 12 deletions docs/content/en/docs/Introduction/_index.md

This file was deleted.

52 changes: 52 additions & 0 deletions docs/content/en/docs/Jikkou CLI/Automating/GitHubActions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
---
title: "Automate Jikkou with GitHub Actions"
linkTitle: "GitHub Actions"
weight: 3
description: >
Learn Jikkou Setup Github Action in your CI/CD Workflows
---

## Setup Jikkou

The [`streamthoughts/setup-jikkou`](https://github.com/streamthoughts/setup-jikkou) action is a JavaScript action that
sets up Jikkou in your **GitHub Actions** workflow by:

* Downloading a specific version of **Jikkou CLI** and adding it to the `PATH`.
* Configuring **JIKKOU CLI** with a custom configuration file.

After you've used the action, subsequent steps in the same job can run arbitrary Jikkou commands using the GitHub
Actions run syntax. This allows most Jikkou commands to work exactly like they do on your local command line.

### Usage

```yaml
steps:
- uses: streamthoughts/setup-jikkou@v1
```
A specific version of Jikkou CLI can be installed:
```yaml
steps:
- uses: streamthoughts/[email protected]
with:
jikkou_version: 0.29.0
```
A custom configuration file can be specified:
```yaml
steps:
- uses: streamthoughts/[email protected]
with:
jikkou_config: ./config/jikkouconfig.json
```
### Inputs
This Action additionally supports the following inputs :
| Property | Default | Description |
|------------------|----------|--------------------------------------------------------------------------------------------------------------------------------|
| `jikkou_version` | `latest` | The version of Jikkou CLI to install. A value of `latest` will install the latest version of Jikkou CLI. |
| `jikkou_config` | | The path to the Jikkou CLI config file. If set, Jikkou CLI will be configured through the `JIKKOUCONFIG` environment variable. |
8 changes: 8 additions & 0 deletions docs/content/en/docs/Jikkou CLI/Automating/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: "Automating Jikkou"
linkTitle: "Automating Jikkou"
weight: 3
description: >
Learn automating Jikkou
---

74 changes: 74 additions & 0 deletions docs/content/en/docs/Jikkou CLI/Basic-CLI-Features.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
---
title: "Basic CLI Features"
linkTitle: "Basic CLI Features"
weight: 1
description:
---

{{% pageinfo %}}
**Hands-on:** Try the Jikkou: [Get Started tutorials]({{% relref "../Tutorials/get_started.md" %}}).
{{% /pageinfo %}}

The command line interface to **Jikkou** is the `jikkou` command, which accepts a variety of subcommands such as
`jikkou apply` or `jikkou validate`.

To view a list of the commands available in your current Jikkou version, run `jikkou` with no additional arguments:

```bash
Usage:
jikkou [-hV] [COMMAND]


Jikkou CLI:: A command-line client designed to provide an efficient and easy way to manage, automate, and provision resources for any kafka infrastructure.

Find more information at: https://streamthoughts.github.io/jikkou/.

Options:

-h, --help Show this help message and exit.
-V, --version Print version information and exit.

Commands:

create Create resources from the resource definition files (only non-existing resources will be created).
delete Delete resources that are no longer described by the resource definition files.
update Create or update resources from the resource definition files
apply Update the resources as described by the resource definition files.
resources List supported resources
extensions List or describe the extensions of Jikkou
config Sets or retrieves the configuration of this client
diff Display all resource changes.
validate Validate resource definition files.
health Print or describe health indicators.
help Display help information about the specified command.
get List and describe all resources of a specific kind.
```

(The output from your current Jikkou version may be different than the above example.)

## Checking Jikkou Version

Run the `jikkou --version` to display your current installation version:

```bash 2 ↵
Jikkou version "0.29.0" 2023-09-29
JVM: 17.0.7 (Oracle Corporation Substrate VM 17.0.7+8-LTS)
```

## Shell Tab-completion

It is recommended to install the bash/zsh completion script `jikkou_completion`.

The completion script can be downloaded from the project Github repository:

```bash
wget https://raw.githubusercontent.com/streamthoughts/jikkou/main/jikkou_completion . jikkou_completion
```

or alternatively, you can run the following command to generate it.

```bash
source <(jikkou generate-completion)
```


Original file line number Diff line number Diff line change
@@ -1,84 +1,16 @@
---
title: "Using Jikkou"
linkTitle: "Using Jikkou"
weight: 3
title: "CLI Configuration"
linkTitle: "CLI Configuration"
weight: 2
description: >
This guide shows the basics of using Jikkou to manage resource entities on your Apache Kafka cluster.
Learn how to configure Jikkou CLI.
---


{{% pageinfo %}}
This guide explains the basics of using Jikkou to manage resource entities on your Apache Kafka cluster.
It assumes that you have already installed the [Jikkou](./_installation.md) client. If you are simply interested in running a few quick commands, you may wish to begin with the [Quickstart Guide](./_getting_started.md). This chapter covers the particulars of Jikkou commands, and explains how to configure and use Jikkou.
**Hands-on:** Try the Jikkou: [Get Started tutorials]({{% relref "../Tutorials/get_started.md" %}}).
{{% /pageinfo %}}


## Jikkou Architecture

### Components

Jikkou is a tool which is implemented into two distinct parts:

* The Jikkou Client is a command-line client for end users.
* The Jikkou Java Library provides the logic for executing all operations the Apache Kafka cluster.

The Jikkou library is available on [Maven Central]( https://mvnrepository.com/artifact/io.streamthoughts/jikkou)

**For Maven:**

```xml
<dependency>
<groupId>io.streamthoughts</groupId>
<artifactId>jikkou-api</artifactId>
<version>${jikkou.version}</version>
</dependency>
```

### Implementation

The Jikkou client and library are written in the Java programming language.

It is built on top of the Kafka's [Java AdminClient](https://kafka.apache.org/30/javadoc/org/apache/kafka/clients/admin/Admin.html).
Thus, it works out-of-the-box with most the Apache Kafka distributions and cloud provider managed services (e.g., [Aiven](https://aiven.io/), [Confluent Cloud](https://confluent.cloud/), etc).

The tool is completely **stateless** and thus does not store any state. Basically: _Your kafka cluster is the state of Jikkou_.

Configuration files are written in [YAML](https://yaml.org/).

## CLI Usage

```bash
$ jikkou help

Usage:
jikkou [-hV] [COMMAND]


Jikkou streamlines the management of the configurations that live on your data streams platform.

Find more information at: https://streamthoughts.github.io/jikkou/.

Options:

-h, --help Show this help message and exit.
-V, --version Print version information and exit.

Commands:

create Create resources from the resource definition files (only non-existing resources will be created).
delete Delete resources that are no longer described by the resource definition files.
update Create or update resources from the resource definition files
apply Update the resources as described by the resource definition files.
resources List supported resources
extensions List or describe the extensions of Jikkou
config Sets or retrieves the configuration of this client
diff Display all resource changes.
validate Validate resource definition files.
health Print or describe health indicators.
help Display help information about the specified command.
get List and describe all resources of a specific kind.
```

## Configuration

To set up the configuration settings used by Jikkou CLI, you will need create a _jikkou config file_, which is created
Expand All @@ -92,21 +24,22 @@ By default, the configuration of `jikkou` is located under the path `~/.jikkou/c

This _jikkou config file_ defines all the contexts that can be used by jikkou CLI.

For example, below is the config file created during the [Getting Started]({{< relref "./getting_started.md" >}}).
For example, below is the config file created during the [Getting Started]({{< relref "../Tutorials/get_started.md" >}}).

```json
{
"currentContext" : "localhost",
"localhost" : {
"currentContext": "localhost",
"localhost": {
"configFile": null,
"configProps" : {
"kafka.client.bootstrap.servers" : "localhost:9092"
"configProps": {
"kafka.client.bootstrap.servers": "localhost:9092"
}
}
}
```

Most of the time, a _context_ does not directly contain the configuration properties to be used, but rather points to a specific
Most of the time, a _context_ does not directly contain the configuration properties to be used, but rather points to a
specific
[HOCON (Human-Optimized Config Object Notation)](https://github.com/lightbend/config) through the (`configFile`).

Then, the `configProps` allows you to override some of the property define by this file.
Expand All @@ -117,8 +50,8 @@ those following locations:
* `./application.conf`
* `$HOME/.jikkou/application.conf`


Finally, Jikkou always fallback to a reference configuration (see [reference.conf](https://github.com/streamthoughts/jikkou/blob/main/jikkou-cli/src/main/resources/reference.conf)).
Finally, Jikkou always fallback to a reference configuration (
see [reference.conf](https://github.com/streamthoughts/jikkou/blob/main/jikkou-cli/src/main/resources/reference.conf)).

```hocon
jikkou {
Expand All @@ -128,7 +61,7 @@ jikkou {
# Kafka Extension
kafka {
# The default Kafka AdminClient configuration
client {
client {
bootstrap.servers = "localhost:9092"
bootstrap.servers = ${?JIKKOU_DEFAULT_KAFKA_BOOTSTRAP_SERVERS}
}
Expand Down Expand Up @@ -189,5 +122,6 @@ jikkou {
You can use `jikkou config view` to show the configuration currently used by your client.

{{% alert title="Tips" color="info" %}}
To debug the configuration use by Jikkou, you can run the following command: `jikkou config view --comments` or `jikkou config view --debug`
{{% /alert %}}
To debug the configuration use by Jikkou, you can run the following command: `jikkou config view --comments`
or `jikkou config view --debug`
{{% /alert %}}
12 changes: 12 additions & 0 deletions docs/content/en/docs/Jikkou CLI/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
title: "Jikkou CLI Documentation"
linkTitle: "Jikkou CLI"
weight: 3
description: >
Learn Jikkou's CLI-based workflows.
---

{{% pageinfo %}}
**Hands-on:** Try the Jikkou: [Get Started tutorials]({{% relref "../Tutorials/get_started.md" %}}).
{{% /pageinfo %}}

Loading

0 comments on commit 927d0c7

Please sign in to comment.