Environment Variable Configuration
Running Arseeding requires a number of environment variables to be configured as a way to configure the running storage mode, cost mode, etc. These environment variables and their roles are described below.
Environment Variable | Description |
---|---|
DB_DIR | Storage path for data when running with local storage mode(e.g ./data/bolt) |
MYSQL | Mysql DSN root:password@tcp(ip:port)/dbName?parameter, root is your mysql user name,A database named dbName needs to be prepared in advance in your mysql (e.g root:123456@tcp(127.0.0.1:3306)/arseed?charset=utf8mb4&parseTime=True&loc=Local) Note: parseTime=True must be configured, Arseeding uses the time. The Time field automatically generates the creation time and update time of the record |
USE_SQLITE | To use sqlite instead of mysql, you can set this environment variable to true, if not set or set to false, means use mysql |
SQLITE_DIR | To customize the sqlite database path, you can configure this environment variable, the default is "./data/sqlite" |
KEY_PATH | To run Arseeding you must provide an AR wallet (keyfile) so that you can upload the data that users pass to Arseeding to Arweave. How do I create a keyfile? |
AR_NODE | Arweave node, typically configured as an Arweave gateway (https://arweave.net), you can also configure it as a local node (http://127.0.0.1:8080), as Arseeding is compatible with the gateway as a light node |
PAY | Upload data to Arseeding's payment interface, configured as (https://api.everpay.io) if using a public service. You don’t need to configure this if using No_Fee mode. |
NO_FEE | Boolean value, set to true for No_Fee mode |
USE_S3 | Boolean value, set to true for S3 storage mode |
S3_ACC_KEY | S3 or 4everland API Access Key,How to Get the API Key ? |
S3_SECRET_KEY | S3 or 4everland API Secret Key |
S3_PREFIX | S3 or 4everland buckets cannot have the same name in the same region (e.g. Asia Pacific), you need to check which regions you can create buckets in and, when starting Arseeding, you need to provide an appropriate bucket prefix to ensure that the bucket you create does not have the same name as another S3 user's bucket. |
S3_REGION | Configure which region your S3 bucket is located in and you can see which regions you can create buckets in at AWS S3 (e.g ap-northeast-1) |
USE_4EVER | Boolean value, set to true for 4everland storage mode (4everland storage mode also requires importing the USE_S3=true environment variable) |
USE_ALIYUN | Boolean value, set to true for aliyun oss storage mode (You cannot set USE_ALIYUN and USE_S3 to true at the same time, you can only choose one of the two) |
ALIYUN_ENDPOINT | The endpoint URL of aliyun OSS |
ALIYUN_ACC_KEY | API Access Key of aliyun OSS |
ALIYUN_SECRET_KEY | API Secret Key of aliyun OSS |
ALIYUN_PREFIX | bucket prefix of aliyun OSS |
PORT | Arseeding service port, default is 8080,you can config it.PORT=":9090" |