Table of Contents
- Supported Platforms
- Requirements
- Environment Variables
- Dependencies
- Example Run
- License
- Author Information
Container file that installs, configures and launches Lotus: an implementation of the Filecoin distributed storage network protocol written in Go.
* Redhat(CentOS/Fedora)
* Debian
* Ubuntu
None
Variables are available and organized according to the following software & machine provisioning stages:
- install
- config
- launch
The following variables can be customized to control aspects of the installation process for both the Lotus client and storage miner involving where operational artifacts are stored.
$LOTUS_PATH: (default: /root/.lotus/)
- path within container the
lotusservice should establish as its runtime configuration and data directory
$LOTUS_STORAGE_PATH: (default: /root/.lotusstorage/)
- path within container the
lotus-storage-minerservice should establish as its runtime and data storage directory.
Configuration of the lotus client can be expressed in a config file written in TOML, a minimal markup language. Note: This file can be found under the directory specified by the LOTUS_PATH (for the lotus client/service) or LOTUS_STORAGE_PATH (for the lotus miner) environment variables. For an idea of the available configuration options, reference this example (installed by default).
The following variables can be customized to manage the content of this TOML configuration:
$CONFIG_<section-keyword>_<section-property> = <property-value (string)> default: None
- Any configuration setting/value key-pair supported by
lotusshould be expressible within eachCONFIG_*environment variable and properly rendered within the associated TOML config. Note:<section-keyword>along with the other property specifications should be written as expected to be rendered within the associatedTOMLconfig (e.g. Libp2p).
Furthermore, configuration is not constrained by hardcoded author defined defaults or limited by pre-baked templating. Only configurations specified by the operator are rendered within the configuration file. Also if the config section, setting and value are recognized by the lotus tool, 👍 to define within an environnment variable according to the following syntax.
<section-keyword> -- represents TOML config sections:
# [TOML Section 'Metrics']
CONFIG_Metrics_<section-property>=<property-value><section-property> -- represents a specific TOML config section property to configure:
# [TOML Section 'Metrics']
# Property: PubsubTracing
CONFIG_Metrics_PubsubTracing=<property-value><property-value> -- represents property value to configure:
# [TOML Section 'Metrics']
# Property: PubsubTracing
# Value: true
CONFIG_Metrics_PubsubTracing=true # enable publish-subscription tracing for performance monitoring/troubleshootingRunning of the lotus client and API server as well as the lotus-storage-miner service is accomplished using official Lotus binaries, obtained from Filecoin's Lotus github site.
The following variables can be customized to manage the Lotus client and Lotus Storage miner execution profiles/policies:
$MANAGED_SERVICES = <lotus|lotus-storage-miner> (default: )
- list of Lotus services to manage and launch
$EXTRA_ARGS: <lotus-cli-options> (default: NONE)
- list of
lotus daemoncommandline arguments to pass to the binary at runtime for customizing launch
See here for an example of the lotus daemon's cli.
$EXTRA_MINER_ARGS: <lotus-storage-miner-cli-options> (default: NONE)
- list of
lotus-storage-miner runcommandline arguments to pass to the binary at runtime for customizing launch.
See here for an example of the lotus-storage-miner run's cli.
None
default example:
podman run 0labs/0x01.lotus:0.2.10_ubuntu-19.10only manage launch of the lotus client and API server:
podman run --env MANAGED_SERVICES=lotus 0labs/0x01.lotus:0.2.10_ubuntu-19.10expose lotus API/JSON-RPC server on non-loopback (wildcard/*) address
podman run --env CONFIG_API_ListenAddress= /ip4/0.0.0.0/tcp/1234/http \
--env CONFIG_Libp2p_ListenAddress=/ip4/0.0.0.0/tcp/1234/http \
0labs/0x01.lotus:0.2.10_fedora-31launch lotus service and lotus-storage-miner agents with custom runtime/storage paths and launch options:
podman run --env MANAGED_SERVICES="lotus lotus-storage-miner" \
--env LOTUS_PATH=/mnt/lotus \
--env LOTUS_STORAGE_PATH=/mnt/lotus/miner \
--env CONFIG_Metrics_Nickname=example_miner \
--env EXTRA_ARGS=--bootstrap \
--env EXTRA_MINER_ARGS=--nosync \
0labs/0x01.lotus:0.2.10_debian-10MIT
This Containerfile was created in 2020 by O1.IO.