@@ -30,7 +30,6 @@ const (
3030 DockerComposeFile = "./docker-compose.nodes.yml"
3131 DockerComposeFileVersion = "3.7"
3232 PrometheusTargetsFile = "./targets.nodes.json"
33- DefaultAccessGatewayName = "access_1"
3433 DefaultObserverName = "observer"
3534 DefaultLogLevel = "DEBUG"
3635 DefaultGOMAXPROCS = 8
@@ -468,9 +467,9 @@ func prepareObserverService(i int, observerName string, agPublicKey string) Serv
468467
469468 observerService := defaultService (DefaultObserverName , dataDir , profilerDir , i )
470469 observerService .Command = append (observerService .Command ,
471- fmt .Sprintf ("--bootstrap-node-addresses=%s:%d" , DefaultAccessGatewayName , AccessPubNetworkPort ),
470+ fmt .Sprintf ("--bootstrap-node-addresses=%s:%d" , testnet . PrimaryAN , AccessPubNetworkPort ),
472471 fmt .Sprintf ("--bootstrap-node-public-keys=%s" , agPublicKey ),
473- fmt .Sprintf ("--upstream-node-addresses=%s:%d" , DefaultAccessGatewayName , SecuredRPCPort ),
472+ fmt .Sprintf ("--upstream-node-addresses=%s:%d" , testnet . PrimaryAN , SecuredRPCPort ),
474473 fmt .Sprintf ("--upstream-node-public-keys=%s" , agPublicKey ),
475474 fmt .Sprintf ("--observer-networking-key-path=/bootstrap/private-root-information/%s_key" , observerName ),
476475 "--bind=0.0.0.0:0" ,
@@ -480,7 +479,7 @@ func prepareObserverService(i int, observerName string, agPublicKey string) Serv
480479 )
481480
482481 // observer services rely on the access gateway
483- observerService .DependsOn = append (observerService .DependsOn , DefaultAccessGatewayName )
482+ observerService .DependsOn = append (observerService .DependsOn , testnet . PrimaryAN )
484483 observerService .Ports = []string {
485484 // Flow API ports come in pairs, open and secure. While the guest port is always
486485 // the same from the guest's perspective, the host port numbering accounts for the presence
@@ -643,12 +642,12 @@ func openAndTruncate(filename string) (*os.File, error) {
643642
644643func getAccessGatewayPublicKey (flowNodeContainerConfigs []testnet.ContainerConfig ) (string , error ) {
645644 for _ , container := range flowNodeContainerConfigs {
646- if container .ContainerName == DefaultAccessGatewayName {
645+ if container .ContainerName == testnet . PrimaryAN {
647646 // remove the "0x"..0000 portion of the key
648647 return container .NetworkPubKey ().String ()[2 :], nil
649648 }
650649 }
651- return "" , fmt .Errorf ("Unable to find public key for Access Gateway expected in container '%s'" , DefaultAccessGatewayName )
650+ return "" , fmt .Errorf ("Unable to find public key for Access Gateway expected in container '%s'" , testnet . PrimaryAN )
652651}
653652
654653func prepareObserverServices (dockerServices Services , flowNodeContainerConfigs []testnet.ContainerConfig ) Services {
@@ -685,7 +684,7 @@ func prepareObserverServices(dockerServices Services, flowNodeContainerConfigs [
685684 }
686685 fmt .Println ()
687686 fmt .Println ("Observer services bootstrapping data generated..." )
688- fmt .Printf ("Access Gateway (%s) public network libp2p key: %s\n \n " , DefaultAccessGatewayName , agPublicKey )
687+ fmt .Printf ("Access Gateway (%s) public network libp2p key: %s\n \n " , testnet . PrimaryAN , agPublicKey )
689688
690689 return dockerServices
691690}
0 commit comments