Skip to content

Commit

Permalink
Merge branch 'master' into doc-smdk-test-stdin
Browse files Browse the repository at this point in the history
  • Loading branch information
tjtelan authored Dec 1, 2023
2 parents 158d873 + 1eb5d80 commit 753f638
Show file tree
Hide file tree
Showing 256 changed files with 2,273 additions and 1,178 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: 2 additions & 2 deletions .github/workflows/check_examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,10 @@ jobs:
steps:
- name: Dump context
uses: crazy-max/ghaction-dump-context@v2.0.0
- uses: actions/checkout@v3
- uses: actions/checkout@v4
if: ${{ needs.test-skip-check.outputs.no-skip }}

- uses: actions/checkout@v3
- uses: actions/checkout@v4
if: ${{ needs.test-skip-check.outputs.no-skip }}
with:
repository: infinyon/fluvio
Expand Down
13 changes: 6 additions & 7 deletions .github/workflows/htmltest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,7 @@ concurrency:
cancel-in-progress: true

on:
push:
branches:
- staging
- trying
merge_group:
pull_request:
branches: [master]
workflow_dispatch:
Expand All @@ -35,7 +32,7 @@ jobs:

- name: Checkout code
if: ${{ needs.test-skip-check.outputs.no-skip }}
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 1
- name: Setup Hugo
Expand All @@ -44,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 All @@ -57,7 +56,7 @@ jobs:
# Used by Bors to detect that all required jobs have completed successfully
done:
name: Pass html lint
if: github.event_name == 'push' && github.ref == 'refs/heads/staging'
if: github.event_name == 'merge_group'
needs: htmltest
runs-on: ubuntu-latest
steps:
Expand Down
23 changes: 7 additions & 16 deletions .github/workflows/screenshots.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,8 @@ concurrency:
cancel-in-progress: true

on:
merge_group:
push:
branches:
- staging
- trying
pull_request:
branches: [master]
workflow_dispatch:
Expand All @@ -35,12 +33,13 @@ jobs:
run: npm install --global capture-website-cli

# Checkout and build files of a base ref.
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.base.sha }}
path: current_repo

# Checkout and build files of a head ref.
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
clean: false # Prevent removing files in 'path/to/base' folder.
Expand Down Expand Up @@ -78,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 All @@ -101,13 +102,3 @@ jobs:
with:
name: changed-screenshots
path: /tmp/changed-screenshots

#- uses: actions/upload-artifact@v3
# with:
# name: base-site
# path: ./base

#- uses: actions/upload-artifact@v3
# with:
# name: pr-site
# path: "./head"
4 changes: 2 additions & 2 deletions .github/workflows/skip-test-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@ jobs:
no-skip: ${{ ! steps.outputs.skip_label_check.result }}
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Dump context
uses: crazy-max/ghaction-dump-context@v2.0.0

- name: Checkout code for push
if: github.event_name == 'push' && github.ref == 'refs/heads/staging'
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Get PR Number from event
if: github.event_name == 'pull_request'
Expand Down
15 changes: 12 additions & 3 deletions .github/workflows/update-connector-docs.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,19 @@
name: Connector docs PR

permissions:
contents: read

concurrency:
group: connector-docs-${{ github.ref }}
cancel-in-progress: true

on:
#push:
# branches:
# - staging
# - trying
#pull_request:
# branches: [master]
workflow_call:
workflow_dispatch:
schedule:
Expand All @@ -17,19 +26,19 @@ jobs:
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Install Fluvio
run: |
curl -fsS https://hub.infinyon.cloud/install/install.sh | bash
echo "$HOME/.fluvio/bin" >> $GITHUB_PATH
- name: Fluvio Login
run: fluvio cloud login --email ${{ secrets.CLOUD_USER_EMAIL }} --password ${{ secrets.CLOUD_USER_PASSWORD }}

- uses: Swatinem/rust-cache@v2
# Run fluvio cms

- name: Run connector docs update
run: cargo run -- connector --prod
run: cargo run -- connector

# Create/Update PR
- name: Create Pull Request
Expand Down
37 changes: 30 additions & 7 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

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
```
cargo run -- hugo
```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.
6 changes: 0 additions & 6 deletions bors.toml

This file was deleted.

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" >}})
Loading

0 comments on commit 753f638

Please sign in to comment.