webui

package
v1.5.0-dev2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 2, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

README

Bacalhau WebUI

Dependencies

You will need to install all the dependencies in the .tool-versions file.

asdf install

Then install corepack which you'll need for the latest yarn version.

npm install -g corepack
corepack prepare yarn@latest --activate

Install all yarn dependencies

yarn install

Spinning up the Dashboard for Development:

For spinning up & testing the dashboard with the API connection to the bacalhau network you can run:

cd webui

yarn run build

cd..

make build

./bin/$(go env GOOS)/$(go env GOARCH)/bacalhau serve --node-type=requester,compute --peer=none --web-ui

The above will spin up your own bacalhau cluster. This will use the default port 1234. Visit http://127.0.0.1/ to see WebUI.

Interaction with Bacalhau

In bacalhau.ts you will find Bacalhau API configuration.

webui.go serves as a web server to deliver the webui (React code), handling both the serving of static assets embedded in the binary and dynamic routing for client-side navigation.

Learn More

You can learn more in the Create React App documentation.

To learn React, check out the React documentation.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IndexPage

func IndexPage(host, port, base string) ([]byte, error)

Return the index page for the web app with the passed API URL used. The app running on each client will attempt to connect to the API URL to retrieve job and node information.

func ListenAndServe

func ListenAndServe(ctx context.Context, host, apiPort, apiPath string, listenPort int) error

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL