Skip to content

Commit

Permalink
Update Fluvio live site with master updates (#733)
Browse files Browse the repository at this point in the history
* docs: Cli update (#721)

* Update CLI docs

* Rearrange nav a bit
* Removing the infinyon banner too

* Update command

* Update labels

* First pass updates to docs page (#726)

* docs cleanup (#732)

* Modify  `smdk test` examples and documentation to use `--stdin` (#666)

* Remove deprecated script from readme

* Modify `smdk test` examples and doc to use `--stdin`

---------

Co-authored-by: T.J. Telan <t.telan@gmail.com>

---------

Co-authored-by: T.J. Telan <t.telan@gmail.com>
Co-authored-by: Consoli <matheus.consoli7@gmail.com>
  • Loading branch information
3 people authored Dec 2, 2023
1 parent a61a441 commit 9a41281
Show file tree
Hide file tree
Showing 134 changed files with 901 additions and 952 deletions.
7 changes: 2 additions & 5 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,11 @@
"cli:cloud":
- "content/cli/cloud/**"

"cli:commands":
- "content/cli/commands/**"

"cli:connectors":
- "content/cli/connectors/**"

"cli:local":
- "content/cli/local/**"
"cli:install":
- "content/cli/install/**"

"cli:smartmodules":
- "content/cli/smartmodules/**"
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/htmltest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,11 @@ jobs:
with:
hugo-version: '0.97.3'
extended: true

- uses: Swatinem/rust-cache@v2
- name: Run Hugo in the background
if: ${{ needs.test-skip-check.outputs.no-skip }}
run: ./hugo-start.sh &
run: cargo run -- hugo &
# Skip running for now
- name: Run htmltest
if: ${{ false }}
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/screenshots.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,12 @@ jobs:
find . -name "*.html" -exec diff --brief --new-file base/{} {} \; | awk '{print $4}' | sed 's/./http:\/\/localhost:1313/' | tee /tmp/changed-html.txt
wc /tmp/changed-html.txt
- uses: Swatinem/rust-cache@v2

- name: Start Hugo server and take screenshots
run: |
cd pr_repo
./hugo-start.sh &
cargo run -- hugo &
sleep 5
mkdir /tmp/changed-screenshots
Expand Down
47 changes: 30 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,24 @@
# Fluvio Website

Fluvio website repository stores all documentation published in [fluvio.io](https://fluvio.io).
## Public/Nightly Websites

[Cloudflare Pages](https://pages.cloudflare.com/) watches the default branch, and updates the live site automatically after merge

* master branch - [preview environment](https://master.fluvio-website-preview.pages.dev/)
* stable branch - [prod environment (fluvio.io)](https://fluvio.io)

If you create branches in this repo (i.e., not on a fork), Cloudflare will build and provide a url to the Hugo site for each PR. Their URLS are dynamic, based on the name of your branch + `.fluvio-website-preview.pages.dev`

For more info read: https://developers.cloudflare.com/pages/platform/preview-deployments/#preview-aliases

## Run Website on Local Machine

The website is generated using [Hugo Framework](https://gohugo.io/). To run the website on your local machine:

1. [Install Hugo](https://gohugo.io/getting-started/installing/)
2. Run Hugo
```
./hugo-start.sh
```shell
cargo run -- hugo
```
3. Website is rendered at
```
Expand All @@ -21,19 +30,7 @@ The website is generated using [Hugo Framework](https://gohugo.io/). To run the
Hugo watches for file changes and automatically updates website.


## Public/Nightly Websites

[Cloudflare Pages](https://pages.cloudflare.com/) watches the default branch, and updates the live site automatically after merge

* `master` updates [fluvio.io](https://fluvio.io)

Preview pages are created for each PR. Their URLS are dynamic, based on the name of your branch + `.fluvio-website-preview.pages.dev`

For more info read: https://developers.cloudflare.com/pages/platform/preview-deployments/#preview-aliases

Or ask someone with access to the Pages dashboard to retrieve your preview URL

## Connector-beta reference docs
## Connector reference docs

A preview of the `fluvio-cms` CLI can be used to update the reference docs for connectors in the Hub.

Expand Down Expand Up @@ -66,4 +63,20 @@ Using README from local git clone:
Ex. Copy SQL docs
```shell
$ cargo run -- connector --service sql --direction outbound --file /path/to/README
```
```
## CLI docs
### Update help text
The list of CLI commands is located at `/data/cli-commands.yml`
Running this command will iterate through the list of CLI commands and capture the output of the `--help` flag
```shell
$ cargo run -- cli
```
This creates files in `/embed/cli/help` with the filename pattern `<cmd>[-<subcmd1>][-<subcmd2][-subcmd3etc].md`. The help output for the command `fluvio cluster list` would be located at `/embed/cli/help/fluvio-cluster-list.md`
The templates for the CLI pages in https://www.fluvio.io/cli/ are not generated. Any commands that are added or removed may need to modify additional files.
2 changes: 1 addition & 1 deletion content/_globals.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
---
houseAdd: 'We are hiring! <a href="https://infinyon.com/careers/" target="_blank">Apply here</a>'
#houseAdd: 'We are hiring! <a href="https://infinyon.com/careers/" target="_blank">Apply here</a>'
careersLink: "https://infinyon.com/careers/"
---
17 changes: 8 additions & 9 deletions content/cli/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,22 @@ out with Fluvio:

#### Setting up a cluster

- [Create your own Fluvio cluster with `fluvio cluster start`]({{< ref "/cli/local/cluster#fluvio-cluster-start" >}})
- [Connect to your Fluvio Cloud cluster with `fluvio cloud login`]({{< ref "cli/cloud/overview#fluvio-cloud-login" >}})
- [Create your own Fluvio cluster with `fluvio cluster start`]({{< ref "/cli/cluster/cluster#fluvio-cluster-start" >}})

#### Sending and Receiving data from Fluvio

- [Create a topic with `fluvio topic create`]({{< ref "/cli/commands/topic#fluvio-topic-create" >}})
- [Produce data to a topic with `fluvio produce`]({{< ref "/cli/commands/produce#fluvio-produce" >}})
- [Consume data from a topic with `fluvio consume`]({{< ref "/cli/commands/consume#fluvio-consume" >}})
- [Create a topic with `fluvio topic create`]({{< ref "/cli/cluster/topic#fluvio-topic-create" >}})
- [Produce data to a topic with `fluvio produce`]({{< ref "/cli/client/produce#fluvio-produce" >}})
- [Consume data from a topic with `fluvio consume`]({{< ref "/cli/client/consume#fluvio-consume" >}})

#### Enriching data with SmartModules

- [Overview for SmartModules]({{< ref "/smartmodules" >}})
- [Write a custom filtering SmartModule]({{< ref "/smartmodules/transform/filter" >}})
- [Consume enriched data using SmartModules]({{< ref "/cli/commands/consume#example-3-consume-using-a-smartstream" >}})
- [Consume enriched data using SmartModules]({{< ref "/cli/client/consume#example-3-consume-using-a-smartstream" >}})

#### Viewing the status of the cluster

- [See all of your topics with `fluvio topic list`]({{< ref "/cli/commands/topic#fluvio-topic-list" >}})
- [See your partitions and data replication with `fluvio partition list`]({{< ref "/cli/commands/partition#fluvio-partition-list" >}})
- [See the status of the SPUs in your cluster with `fluvio cluster spu list`]({{< ref "/cli/local/cluster#fluvio-cluster-spu-list" >}})
- [See all of your topics with `fluvio topic list`]({{< ref "/cli/cluster/topic#fluvio-topic-list" >}})
- [See your partitions and data replication with `fluvio partition list`]({{< ref "/cli/cluster/partition#fluvio-partition-list" >}})
- [See the status of the SPUs in your cluster with `fluvio cluster spu list`]({{< ref "/cli/cluster/cluster#fluvio-cluster-spu-list" >}})
32 changes: 19 additions & 13 deletions content/cli/advanced/runner.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,20 @@ over the components, then you can do so using `fluvio run`.

[Streaming Controller (SC)]: {{< ref "/docs/architecture/sc" >}}
[Streaming Processing Unit (SPU)]: {{< ref "/docs/architecture/spu" >}}
[`fluvio cluster`]: {{< ref "/cli/local/cluster" >}}
[`fluvio cluster`]: {{< ref "/cli/cluster/cluster" >}}

{{% inline-embed file="embeds/cli/help/fluvio-run.md" %}}

## `fluvio run spu`

Directly invokes a Streaming Processing Unit (SPU) from the command line.
An SPU has a public server which is used to stream data to and from Fluvio Clients, and
a private server which is used to communicate with an SC. Most of the CLI options for
the SPU involve configuring these servers. See the [SPU Architecture] for more details.

[SPU Architecture]: {{< ref "/docs/architecture/spu" >}}

{{% inline-embed file="embeds/cli/help/fluvio-run-spu.md" %}}

## `fluvio run sc`

Expand All @@ -26,15 +39,8 @@ the CLI options for the SC involve configuring these servers. See the

{{% inline-embed file="embeds/cli/help/fluvio-run-sc.md" %}}

---

## `fluvio run spu`

Directly invokes a Streaming Processing Unit (SPU) from the command line.
An SPU has a public server which is used to stream data to and from Fluvio Clients, and
a private server which is used to communicate with an SC. Most of the CLI options for
the SPU involve configuring these servers. See the [SPU Architecture] for more details.

[SPU Architecture]: {{< ref "/docs/architecture/spu" >}}

{{% inline-embed file="embeds/cli/help/fluvio-run-spu.md" %}}
## `fluvio run metadata`
{{% inline-embed file="embeds/cli/help/fluvio-run-metadata.md" %}}
p
## `fluvio run version`
{{% inline-embed file="embeds/cli/help/fluvio-run-version.md" %}}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ The `consume` command will only read from one of those partitions, defaulting to

{{% inline-embed file="embeds/cli/help/fluvio-consume.md" %}}

The following `fluvio consume` examples come after the [`fluvio produce` examples]({{< ref "/cli/commands/produce" >}}).
The following `fluvio consume` examples come after the [`fluvio produce` examples]({{< ref "/cli/client/produce" >}}).

## Examples
### Consume all records
Expand Down Expand Up @@ -99,7 +99,7 @@ records from the different partitions in a topic by using the `--partition (-p)`

Start out by creating a new topic with multiple partitions using [`fluvio topic create`].

[`fluvio topic create`]: {{< ref "/cli/commands/topic#fluvio-topic-create" >}}
[`fluvio topic create`]: {{< ref "/cli/cluster/topic#fluvio-topic-create" >}}

%copy first-line%
```bash
Expand Down Expand Up @@ -133,7 +133,7 @@ $ fluvio produce "consume-multi" -f records.txt
After producing some data, let's take a look at how the records got distributed
among our partitions using [`fluvio partition list`].

[`fluvio partition list`]: {{< ref "/cli/commands/partition#fluvio-partition-list" >}}
[`fluvio partition list`]: {{< ref "/cli/cluster/partition#fluvio-partition-list" >}}

%copy first-line%
```bash
Expand Down
11 changes: 0 additions & 11 deletions content/cli/client/overview.md

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ a multi-partition topic, then sending some key/value records.

First, we'll use [`fluvio topic create`] to create a topic called `multi-keys` with 5 partitions:

[`fluvio topic create`]: {{< ref "/cli/commands/topic#fluvio-topic-create" >}}
[`fluvio topic create`]: {{< ref "/cli/cluster/topic#fluvio-topic-create" >}}

%copy first-line%
```bash
Expand Down Expand Up @@ -143,7 +143,7 @@ generated 2 events, and `tabitha` generated 3 events. When we look at the partit
we should see the records distributed in groups of 5, 2, and 3. We can use the
[`fluvio partition list`] command to view the distribution of records in our partitions:

[`fluvio partition list`]: {{< ref "/cli/commands/partition#fluvio-partition-list" >}}
[`fluvio partition list`]: {{< ref "/cli/cluster/partition#fluvio-partition-list" >}}

%copy first-line%

Expand All @@ -163,7 +163,7 @@ were distributed in groups of 5, 3, and 2. Let's dig a little further, we know t
`rafael` was the key used by the group of 5 records, so we should be able to see those
records by using [`fluvio consume`] to consume from partition 3.

[`fluvio consume`]: {{< ref "/cli/commands/consume" >}}
[`fluvio consume`]: {{< ref "/cli/client/consume" >}}

%copy first-line%

Expand Down Expand Up @@ -194,7 +194,7 @@ Let's produce some data to our topic. We'll use the same data from [Example 3],
but this time we won't tell the Producer to interpret our input as key-value records
(we'll do this by omitting the `--key-separator` flag).

[Example 3]: {{< ref "/cli/commands/produce#example-3-produce-keyvalue-records-to-multiple-partitions" >}}
[Example 3]: {{< ref "/cli/client/produce#example-3-produce-keyvalue-records-to-multiple-partitions" >}}

```bash
# Put the following records into a text file using your favorite editor
Expand Down Expand Up @@ -247,7 +247,7 @@ Let's try to use `gzip` algorithm in the CLI.

First, we'll use [`fluvio topic create`] to create a topic called `compressed` and other topic called `uncompressed`:

[`fluvio topic create`]: {{< ref "/cli/commands/topic#fluvio-topic-create" >}}
[`fluvio topic create`]: {{< ref "/cli/cluster/topic#fluvio-topic-create" >}}

%copy first-line%
```bash
Expand Down Expand Up @@ -302,4 +302,4 @@ Notice how the SIZE field tell us that the `compressed` topic is using less disk

Also note that, [`consuming`] from topics is done at the same way for both compressed and uncompressed data.

[`consuming`]: {{< ref "/cli/commands/consume" >}}
[`consuming`]: {{< ref "/cli/client/consume" >}}
25 changes: 16 additions & 9 deletions content/cli/client/profile.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Profile details are stored in the Fluvio configuration file at `~/.fluvio/config

Prints out the name of the active Fluvio profile.

[`fluvio topic create greeting`]: {{< ref "/cli/commands/topic#fluvio-topic-create" >}}
[`fluvio topic create greeting`]: {{< ref "/cli/cluster/topic#fluvio-topic-create" >}}

{{% inline-embed file="embeds/cli/help/fluvio-profile-current.md" %}}

Expand All @@ -27,7 +27,7 @@ local

Deletes the specified Fluvio cluster connection profile from your Fluvio configuration (`~/.fluvio/config`).

This will not delete a cluster. See [`fluvio cluster delete`]({{<ref "/cli/local/cluster.md#fluvio-cluster-delete" >}}) for more info.
This will not delete a cluster. See [`fluvio cluster delete`]({{<ref "/cli/cluster/cluster.md#fluvio-cluster-delete" >}}) for more info.

{{% inline-embed file="embeds/cli/help/fluvio-profile-delete.md" %}}

Expand All @@ -36,7 +36,7 @@ This will not delete a cluster. See [`fluvio cluster delete`]({{<ref "/cli/local

Deletes only cluster connection information from your profile.

This will not delete a cluster. See [`fluvio cluster delete`]({{<ref "/cli/local/cluster.md#fluvio-cluster-delete" >}}) for more info.
This will not delete a cluster. See [`fluvio cluster delete`]({{<ref "/cli/cluster/cluster.md#fluvio-cluster-delete" >}}) for more info.

[`fluvio cluster delete`]: {{< ref "/cli/local/cluster#fluvio-cluster-delete" >}}

Expand All @@ -50,12 +50,6 @@ $ fluvio profile delete-cluster local
Cluster local deleted
```

## `fluvio profile switch`

Changes the active CLI profile.

{{% inline-embed file="embeds/cli/help/fluvio-profile-switch.md" %}}

## `fluvio profile list`

Prints a table of your profiles, including the address of the associated
Expand All @@ -73,3 +67,16 @@ $ fluvio profile list
* minikube minikube 10.99.16.213:9003 Disabled
local local localhost:9003 Disabled
```

## `fluvio profile rename`
{{% inline-embed file="embeds/cli/help/fluvio-profile-rename.md" %}}

## `fluvio profile switch`
{{% inline-embed file="embeds/cli/help/fluvio-profile-switch.md" %}}

## `fluvio profile sync`
{{% inline-embed file="embeds/cli/help/fluvio-profile-sync.md" %}}
## `fluvio profile export`
{{% inline-embed file="embeds/cli/help/fluvio-profile-export.md" %}}
## `fluvio profile add`
{{% inline-embed file="embeds/cli/help/fluvio-profile-add.md" %}}
1 change: 1 addition & 0 deletions content/cli/client/update.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: Update
weight: 20
toc: false
hidden: true
---

## `fluvio update`
Expand Down
6 changes: 0 additions & 6 deletions content/cli/cloud/_index.md

This file was deleted.

Loading

0 comments on commit 9a41281

Please sign in to comment.