File tree Expand file tree Collapse file tree 1 file changed +13
-4
lines changed
Expand file tree Collapse file tree 1 file changed +13
-4
lines changed Original file line number Diff line number Diff line change 66 */
77
88import {
9- CANTON_BOOTSTRAP ,
109 SUPPORTED_VERSIONS ,
11- CANTON_CONF ,
1210 error ,
1311 info ,
1412 trimNewline ,
@@ -24,7 +22,6 @@ const processName = 'canton'
2422
2523async function main ( ) {
2624 const network : Network = getNetworkArg ( )
27- const inputCantonConf = getArgValue ( 'config' ) ?? CANTON_CONF
2825
2926 const envConfig = SUPPORTED_VERSIONS [ network ] ?. canton
3027 if ( ! envConfig ) {
@@ -36,6 +33,18 @@ async function main() {
3633 process . exit ( 1 )
3734 }
3835
36+ const networkDir = path . resolve ( `canton/${ network } ` )
37+ const inputCantonConf2 =
38+ getArgValue ( 'config' ) ?? path . join ( networkDir , 'canton.conf' )
39+
40+ const cantonBootstrap = path . join ( networkDir , 'bootstrap.sc' )
41+
42+ console . log (
43+ info (
44+ `usinng bootstrap: ${ cantonBootstrap } and conf ${ inputCantonConf2 } `
45+ )
46+ )
47+
3948 const { version } = envConfig
4049
4150 const CANTON_BIN = path . resolve ( `.canton/${ version } /bin/canton` )
@@ -55,7 +64,7 @@ async function main() {
5564 name : processName ,
5665 interpreter : '/bin/bash' ,
5766 script : CANTON_BIN ,
58- args : `daemon --no-tty --config ${ inputCantonConf } --bootstrap ${ CANTON_BOOTSTRAP } --log-level-stdout=INFO --log-level-canton=INFO` ,
67+ args : `daemon --no-tty --config ${ inputCantonConf2 } --bootstrap ${ cantonBootstrap } --log-level-stdout=INFO --log-level-canton=INFO` ,
5968 } ,
6069 function ( err ) {
6170 pm2 . launchBus ( ( err , bus ) => {
You can’t perform that action at this time.
0 commit comments