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

Can not use custom config file in test mode with '-t' #336

Closed
firmianavan opened this Issue Dec 12, 2018 · 3 comments

Comments

Projects
None yet
2 participants
@firmianavan
Copy link

firmianavan commented Dec 12, 2018

When I start mvsd with -t , it seems like using a hardcode config file path as below:

20181212T102156 INFO [server] mvsd version 0.8.4
20181212T102156 INFO [server] ================= startup ==================
20181212T102156 ERROR [server] ================= startup ==================
20181212T102156 FATAL [server] ================= startup ==================
20181212T102156 INFO [server] Using config file: "$HOME/.metaverse"
20181212T102156 INFO [server] Please wait while the server is starting...
20181212T102156 INFO [node] Starting manual session.
20181212T102156 INFO [server] Seeding is complete.
20181212T102156 INFO [MONGO] Websocket Service listen on 127.0.0.1:8821
20181212T102156 INFO [http] Http Service listen on 127.0.0.1:8820
20181212T102156 INFO [node] Node start height is (0).
20181212T102156 INFO [node] Starting inbound session.
20181212T102156 INFO [node] Starting outbound session.
20181212T102156 INFO [server] Bound public query service to tcp://*:9091
20181212T102156 INFO [server] Server is started.

That means I cannot use the api from outside a docker instance or linux server.
I tried with -c test.conf, -c /absolute/path/test.conf , replace $HOME/.metaverse with the config file, but none of them worked

@luozhaohui

This comment has been minimized.

Copy link
Contributor

luozhaohui commented Dec 13, 2018

the default path for customized config file is $HOME/.metaverse/mvs.conf

@firmianavan

This comment has been minimized.

Copy link
Author

firmianavan commented Dec 14, 2018

I did some tests:

$ ls $HOME/.metaverse
data  debug.log  error.log  hosts.cache  hosts-test.cache  mvs.conf  testnet
$ ./mvsd -c mvs.conf -t
20181214T161651 INFO [server] mvsd version 0.8.4
20181214T161651 INFO [server] ================= startup ==================
20181214T161651 ERROR [server] ================= startup ==================
20181214T161651 FATAL [server] ================= startup ==================
20181214T161651 INFO [server] Using config file: "/chain/etp/testnet/.metaverse"
20181214T161651 INFO [server] Please wait while the server is starting...
$ ./mvsd  -t
20181214T161804 INFO [server] mvsd version 0.8.4
20181214T161804 INFO [server] ================= startup ==================
20181214T161804 ERROR [server] ================= startup ==================
20181214T161804 FATAL [server] ================= startup ==================
20181214T161804 INFO [server] Using config file: "/chain/etp/testnet/.metaverse"
20181214T161804 INFO [server] Please wait while the server is starting...
$ cp $HOME/.metaverse/mvs.conf $HOME/.metaverse/mvs-test.conf
$ ./mvsd  -t
20181214T161938 INFO [server] mvsd version 0.8.4
20181214T161938 INFO [server] ================= startup ==================
20181214T161938 ERROR [server] ================= startup ==================
20181214T161938 FATAL [server] ================= startup ==================
20181214T161938 INFO [server] Using config file: "/chain/etp/testnet/.metaverse/mvs-test.conf"
$ ./mvsd  -c mvs-test.conf -t
20181214T162129 INFO [server] mvsd version 0.8.4
20181214T162129 INFO [server] ================= startup ==================
20181214T162129 ERROR [server] ================= startup ==================
20181214T162129 FATAL [server] ================= startup ==================
20181214T162129 INFO [server] Using config file: "/chain/etp/testnet/.metaverse/mvs-test.conf"
20181214T162129 INFO [server] Please wait while the server is starting...
$ ./mvsd  -c mvs.conf -t
20181214T162314 INFO [server] mvsd version 0.8.4
20181214T162314 INFO [server] ================= startup ==================
20181214T162314 ERROR [server] ================= startup ==================
20181214T162314 FATAL [server] ================= startup ==================
20181214T162314 INFO [server] Using config file: "/chain/etp/testnet/.metaverse/mvs-test.conf"
20181214T162314 INFO [server] Please wait while the server is starting...

The parameter -c did not work in any case, I must have the file mvs-test.conf in directory $HOME/.metaverse/ in test mode

@luozhaohui

This comment has been minimized.

Copy link
Contributor

luozhaohui commented Dec 17, 2018

yes, you are right. you can change the name of the configuration file but not the directory of it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.