From 405797ed9459c291e3a3741fbefc314ac330c576 Mon Sep 17 00:00:00 2001 From: Nicko Guyer Date: Mon, 4 Mar 2024 12:23:43 -0500 Subject: [PATCH] Fix ETHConnect permission issues Signed-off-by: Nicko Guyer --- .../blockchain/ethereum/connector/ethconnect/client.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/internal/blockchain/ethereum/connector/ethconnect/client.go b/internal/blockchain/ethereum/connector/ethconnect/client.go index b027c71a..7b7f9793 100644 --- a/internal/blockchain/ethereum/connector/ethconnect/client.go +++ b/internal/blockchain/ethereum/connector/ethconnect/client.go @@ -28,6 +28,7 @@ import ( "github.com/hyperledger/firefly-cli/internal/blockchain/ethereum" "github.com/hyperledger/firefly-cli/internal/blockchain/ethereum/ethtypes" "github.com/hyperledger/firefly-cli/internal/core" + "github.com/hyperledger/firefly-cli/internal/docker" "github.com/hyperledger/firefly-cli/pkg/types" ) @@ -164,5 +165,13 @@ func getReply(ctx context.Context, ethconnectURL, id string) (*EthconnectReply, } func (e *Ethconnect) FirstTimeSetup(stack *types.Stack) error { + for _, member := range stack.Members { + if err := docker.MkdirInVolume(e.ctx, fmt.Sprintf("%s_ethconnect_data_%s", stack.Name, member.ID), "/abis"); err != nil { + return err + } + if err := docker.MkdirInVolume(e.ctx, fmt.Sprintf("%s_ethconnect_data_%s", stack.Name, member.ID), "/events"); err != nil { + return err + } + } return nil }