Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: introduce new documentation layout #6860

Merged
merged 10 commits into from
Jun 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,6 @@ jobs:
- name: Lint built docs
run: yarn docs:lint:fix

- name: Set up Python
uses: actions/setup-python@v1

- name: Build docs
working-directory: docs
run: yarn && yarn build
Expand Down
28 changes: 28 additions & 0 deletions docs/docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,34 @@ const config: Config = {
locales: ["en"],
},

plugins: [
[
"@docusaurus/plugin-client-redirects",
{
createRedirects(existingPath: string) {
if (
existingPath.includes("/advanced-topics") ||
existingPath.includes("/getting-started") ||
existingPath.includes("/beacon-management") ||
existingPath.includes("/validator-management") ||
existingPath.includes("/logging-and-metrics") ||
existingPath.includes("/bootnode") ||
existingPath.includes("/data-retention")
) {
return ["/run".concat(existingPath)];
} else if (existingPath.includes("/testing") || existingPath.includes("/tools")) {
return ["/contribution".concat(existingPath)];
} else if (existingPath.includes("/lightclient-prover")) {
return ["/libraries".concat(existingPath)];
} else if (existingPath.includes("data-retention.md")) {
return ["/run/beacon-management".concat(existingPath)];
}
return undefined; // Return a falsy value: no redirect created
},
},
],
],

presets: [
[
"classic",
Expand Down
11 changes: 6 additions & 5 deletions docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,10 @@
"write-heading-ids": "docusaurus write-heading-ids"
},
"dependencies": {
"@docusaurus/core": "^3.2.0",
"@docusaurus/preset-classic": "^3.2.0",
"@docusaurus/theme-mermaid": "^3.2.0",
"@docusaurus/core": "^3.4.0",
nflaig marked this conversation as resolved.
Show resolved Hide resolved
"@docusaurus/plugin-client-redirects": "^3.4.0",
"@docusaurus/preset-classic": "^3.4.0",
"@docusaurus/theme-mermaid": "^3.4.0",
"@easyops-cn/docusaurus-search-local": "^0.40.1",
"@mdx-js/react": "^3.0.0",
"clsx": "^2.0.0",
Expand All @@ -25,8 +26,8 @@
"react-dom": "^18.0.0"
},
"devDependencies": {
"@docusaurus/module-type-aliases": "^3.2.0",
"@docusaurus/types": "^3.2.0"
"@docusaurus/module-type-aliases": "^3.4.0",
"@docusaurus/types": "^3.4.0"
},
"browserslist": {
"production": [
Expand Down
File renamed without changes.
21 changes: 0 additions & 21 deletions docs/pages/getting-started/starting-a-node.new.md

This file was deleted.

8 changes: 4 additions & 4 deletions docs/pages/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ title: Home

### Getting started

- Follow the installation method for [source install](./getting-started/installation.md/#build-from-source) or [Docker install](./getting-started/installation.md/#docker-installation) to install Lodestar. Or use our [Lodestar Quickstart scripts](https://github.com/ChainSafe/lodestar-quickstart).
- Install [binaries](./run/getting-started/installation.md/#binaries), follow the installation method for [source install](./run/getting-started/installation.md/#build-from-source) or [Docker install](./run/getting-started/installation.md/#docker-installation) to install Lodestar. Or use our [Lodestar Quickstart scripts](https://github.com/ChainSafe/lodestar-quickstart).
- Use [Lodestar libraries](./supporting-libraries/index.md) in your next Ethereum Typescript project.
- Run a beacon node on [mainnet or a public testnet](./getting-started/starting-a-node.md).
- Utilize the whole stack by [starting a local testnet](./advanced-topics/setting-up-a-testnet.md).
- View the Lodestar [CLI commands and options](./beacon-management/beacon-cli.md)
- Run a beacon node on [mainnet or a public testnet](./run/beacon-management/starting-a-node.md).
- Utilize the whole stack by [starting a local testnet](./contribution/advanced-topics/setting-up-a-testnet.md).
- View the Lodestar [CLI commands and options](./run/beacon-management/beacon-cli.md)
- Prospective contributors can read the [contributing section](./contribution/getting-started.md) to understand how we develop and test on Lodestar.
- If you have questions [submit an issue](https://github.com/ChainSafe/lodestar/issues/new) or join us on [Discord](https://discord.gg/yjyvFRP)!
- Please note our [security policy](./security.md).
Expand Down
8 changes: 4 additions & 4 deletions docs/pages/reference/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

_**Welcome! This page has been moved. Please checkout our new docs layout from the Table of Contents! Below are some helpful links to the CLI pages that were split out from this original document**_

- [Beacon Node CLI](../beacon-management/beacon-cli.md)
- [Validator CLI](../validator-management/validator-cli.md)
- [Bootnode CLI](../bootnode/bootnode-cli.md)
- [Light Client CLI](../lightclient-prover/lightclient-cli.md)
- [Beacon Node CLI](../run/beacon-management/beacon-cli.md)
- [Validator CLI](../run/validator-management/validator-cli.md)
- [Bootnode CLI](../run/bootnode/bootnode-cli.md)
- [Light Client CLI](../libraries/lightclient-prover/lightclient-cli.md)
- [Dev CLI](../contribution/dev-cli.md)
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,6 @@ Configuring your node to store and prune data is key to success. On average you

`keystores`, `keystore-cache` and `peerstore` are not usually very large and are not expected to grow much during normal operation.

Logs can also become quite large so please check out the section on [log management](./logging-and-metrics/log-management.md) for more information.
Logs can also become quite large so please check out the section on [log management](../logging-and-metrics/log-management.md) for more information.

There is really only one flag that is needed to manage the data for Lodestar, [`--dataDir`](./beacon-management/beacon-cli#--datadir). Other than that handling log management is really the heart of the data management story. Beacon node data is what it is. Depending on the execution client that is chosen, there may be flags to help with data storage growth but that is outside the scope of this document.
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Installation

## Binaries

Binaries can be downloaded from [this page](https://github.com/ChainSafe/lodestar/releases/) under the `Assets` section.
jeluard marked this conversation as resolved.
Show resolved Hide resolved

## Docker Installation

The [`chainsafe/lodestar`](https://hub.docker.com/r/chainsafe/lodestar) Docker Hub repository is maintained actively. It contains the `lodestar` CLI preinstalled.
Expand Down Expand Up @@ -81,7 +85,7 @@ Lodestar should now be ready for use.
./lodestar --help
```

See [Command Line Reference](./../reference/cli.md) for further information.
See [Command Line Reference](./../../reference/cli.md) for further information.

### Known Issues

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Configuration
title: Stake with a Validator Client
jeluard marked this conversation as resolved.
Show resolved Hide resolved
---

# Validator Configuration
Expand Down
121 changes: 61 additions & 60 deletions docs/sidebars.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,83 +3,94 @@ import type {SidebarsConfig} from "@docusaurus/plugin-content-docs";
const sidebars: SidebarsConfig = {
tutorialSidebar: [
"index",
"introduction",
{
type: "doc",
label: "Security",
id: "security",
},
Comment on lines -6 to -11
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't find deep references to those page anywhere, imo removing content should be separate from a "layout change" PR

{
type: "category",
label: "Getting Started",
items: ["getting-started/quick-start", "getting-started/installation", "getting-started/starting-a-node"],
},
"data-retention",
{
type: "category",
label: "Beacon Node",
items: [
"beacon-management/beacon-cli",
"beacon-management/networking",
"beacon-management/mev-and-builder-integration",
"beacon-management/syncing",
],
},
{
type: "category",
label: "Validator",
label: "Run A Node",
jeluard marked this conversation as resolved.
Show resolved Hide resolved
items: [
"validator-management/validator-cli",
"validator-management/vc-configuration",
"validator-management/external-signer",
"run/getting-started/quick-start",
"run/getting-started/installation",
{
type: "category",
label: "Beacon node",
collapsed: false,
items: [
"run/beacon-management/starting-a-node",
"run/beacon-management/beacon-cli",
"run/beacon-management/data-retention",
"run/beacon-management/networking",
"run/beacon-management/mev-and-builder-integration",
"run/beacon-management/syncing",
],
},
{
type: "category",
label: "Validator Client",
collapsed: false,
items: [
"run/validator-management/vc-configuration",
"run/validator-management/validator-cli",
"run/validator-management/external-signer",
],
},
{
type: "category",
label: "Logging and Metrics",
collapsed: false,
items: ["run/logging-and-metrics/prometheus-grafana", "run/logging-and-metrics/client-monitoring"],
},
{
type: "category",
label: "Discv5 Bootnode",
collapsed: false,
items: ["run/bootnode/bootnode-cli"],
},
],
},
{
type: "category",
label: "Bootnode",
items: ["bootnode/bootnode-cli"],
},
{
type: "category",
label: "Light Client and Prover",
label: "Developer Tools",
collapsed: false,
items: [
"lightclient-prover/lightclient-cli",
{
type: "doc",
label: "Light Client",
id: "lightclient-prover/lightclient",
type: "category",
label: "Lodestar Light Client",
jeluard marked this conversation as resolved.
Show resolved Hide resolved
items: ["libraries/lightclient-prover/lightclient-cli", "libraries/lightclient-prover/lightclient"],
},
{
type: "doc",
label: "Prover",
id: "lightclient-prover/prover",
type: "category",
label: "Lodestar Light Prover",
jeluard marked this conversation as resolved.
Show resolved Hide resolved
items: ["libraries/lightclient-prover/prover"],
},
],
},
{
type: "category",
label: "Logging and Metrics",
items: ["logging-and-metrics/prometheus-grafana", "logging-and-metrics/client-monitoring"],
},

"supporting-libraries/index",
{
type: "category",
label: "Contributing",
collapsed: false,
items: [
{
type: "doc",
label: "Getting Started",
id: "contribution/getting-started",
type: "category",
label: "Advanced Topics",
collapsed: false,
jeluard marked this conversation as resolved.
Show resolved Hide resolved
items: ["contribution/advanced-topics/setting-up-a-testnet"],
},
"contribution/depgraph",
{
type: "doc",
label: "Dev CLI Reference",
id: "contribution/dev-cli",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dev cli seems gone as well (again)

type: "category",
label: "Development Tools",
items: [
"contribution/tools/debugging",
"contribution/tools/flamegraphs",
"contribution/tools/heap-dumps",
"contribution/tools/core-dumps",
],
},
{
type: "category",
label: "Testing",
collapsed: false,
items: [
"contribution/testing/index",
"contribution/testing/end-to-end-tests",
Expand All @@ -91,16 +102,6 @@ const sidebars: SidebarsConfig = {
},
],
},
{
type: "category",
label: "Tools",
items: ["tools/debugging", "tools/flamegraphs", "tools/heap-dumps", "tools/core-dumps"],
},
{
type: "category",
label: "Advanced Topics",
items: ["advanced-topics/setting-up-a-testnet"],
},
"faqs",
],
};
Expand Down
Loading
Loading