-
Notifications
You must be signed in to change notification settings - Fork 837
Closed
Labels
Description
Describe the bug
I want to run avalanchego under nobody:nogroup by docker.
But the staking key/cert is always created by avalanchego automatically under /home even after add --staking-enabled false option
VER=1.6.5
docker run -it --name avalanchego-${VER} \
--user nobody:nogroup \
-v /data/avalanchego:/data/avalanchego \
-p 9650:9650 -p 9651:9651 \
avaplatform/avalanchego:v${VER} \
/avalanchego/build/avalanchego \
--db-dir /data/avalanchego \
--chain-config-dir /data/avalanchego \
--subnet-config-dir /data/avalanchego \
--staking-enabled false --http-host 0.0.0.0
couldn't load node config: couldn't generate staking key/cert: couldn't create path for cert: mkdir /nonexistent: permission deniedTo Reproduce
Steps to reproduce the behavior.
Expected behavior
A clear and concise description of what you expected to happen.
Operating System
ubuntu 20.04
Additional context
I think need an option to define the homeDir instead of $HOME in config/flags.go and the db-dir chain-config-dir
// Results of parsing the CLI
var (
defaultNetworkName = constants.MainnetName
homeDir = os.ExpandEnv("$HOME")
prefixedAppName = fmt.Sprintf(".%s", constants.AppName)
defaultDataDir = filepath.Join(homeDir, prefixedAppName)By submitting this issue I agree to the Terms and Conditions of the Developer Accelerator Program.
charly37
