Skip to content

Commit d863887

Browse files
authored
Merge branch 'main' into fix-nethermind
2 parents 0f00752 + 187b3aa commit d863887

File tree

14 files changed

+1183
-13
lines changed

14 files changed

+1183
-13
lines changed

.github/workflows/test.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ jobs:
2525
- path: framework
2626
vm: ubuntu-latest
2727
regex: TestStorageMutations
28+
- path: framework
29+
vm: ubuntu-latest
30+
regex: TestDX
2831
- path: wasp
2932
vm: ubuntu22.04-16cores-64GB # ghv-ignore!
3033
regex: TestSmoke
File renamed without changes.

framework/.changeset/v0.10.35.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
- Add function that exports OCR2 keys to the clnode's REST client
1+
- Add function that exports OCR2 keys to the clnode's REST client

framework/.changeset/v0.10.36.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
2+
- Allow to execute arbitrary `ExecConfig` in Docker using our client

framework/.changeset/v0.11.0.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- Add DX tracking package

framework/components/dockercompose/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ require (
2525
github.com/Azure/go-ansiterm v0.0.0-20250102033503-faa5f7b0171c // indirect
2626
github.com/BurntSushi/toml v1.4.0 // indirect
2727
github.com/DefangLabs/secret-detector v0.0.0-20250403165618-22662109213e // indirect
28-
github.com/Masterminds/semver/v3 v3.2.1 // indirect
28+
github.com/Masterminds/semver/v3 v3.4.0 // indirect
2929
github.com/Microsoft/go-winio v0.6.2 // indirect
3030
github.com/acarl005/stripansi v0.0.0-20180116102854-5a71ef0e047d // indirect
3131
github.com/apparentlymart/go-textseg/v15 v15.0.0 // indirect

framework/components/dockercompose/go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ github.com/BurntSushi/toml v1.4.0 h1:kuoIxZQy2WRRk1pttg9asf+WVv6tWQuBNVmK8+nqPr0
1515
github.com/BurntSushi/toml v1.4.0/go.mod h1:ukJfTF/6rtPPRCnwkur4qwRxa8vTRFBF0uk2lLoLwho=
1616
github.com/DefangLabs/secret-detector v0.0.0-20250403165618-22662109213e h1:rd4bOvKmDIx0WeTv9Qz+hghsgyjikFiPrseXHlKepO0=
1717
github.com/DefangLabs/secret-detector v0.0.0-20250403165618-22662109213e/go.mod h1:blbwPQh4DTlCZEfk1BLU4oMIhLda2U+A840Uag9DsZw=
18-
github.com/Masterminds/semver/v3 v3.2.1 h1:RN9w6+7QoMeJVGyfmbcgs28Br8cvmnucEXnY0rYXWg0=
19-
github.com/Masterminds/semver/v3 v3.2.1/go.mod h1:qvl/7zhW3nngYb5+80sSMF+FG2BjYrf8m9wsX0PNOMQ=
18+
github.com/Masterminds/semver/v3 v3.4.0 h1:Zog+i5UMtVoCU8oKka5P7i9q9HgrJeGzI9SA1Xbatp0=
19+
github.com/Masterminds/semver/v3 v3.4.0/go.mod h1:4V+yj/TJE1HU9XfppCwVMZq3I84lprf4nC11bSS5beM=
2020
github.com/Microsoft/go-winio v0.6.2 h1:F2VQgta7ecxGYO8k3ZZz3RS8fVIXVxONVUPlNERoyfY=
2121
github.com/Microsoft/go-winio v0.6.2/go.mod h1:yd8OoFMLzJbo9gZq8j5qaps8bJ9aShtEA8Ipt1oGCvU=
2222
github.com/Microsoft/hcsshim v0.12.9 h1:2zJy5KA+l0loz1HzEGqyNnjd3fyZA31ZBCGKacp6lLg=

framework/docker.go

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,18 @@ func NewDockerClient() (*DockerClient, error) {
114114

115115
// ExecContainer executes a command inside a running container by name and returns the combined stdout/stderr.
116116
func (dc *DockerClient) ExecContainer(containerName string, command []string) (string, error) {
117-
L.Info().Strs("Command", command).Str("ContainerName", containerName).Msg("Executing command")
117+
execConfig := container.ExecOptions{
118+
Cmd: command,
119+
AttachStdout: true,
120+
AttachStderr: true,
121+
}
122+
123+
return dc.ExecContainerOptions(containerName, execConfig)
124+
}
125+
126+
// ExecContainer executes a command inside a running container by name and returns the combined stdout/stderr.
127+
func (dc *DockerClient) ExecContainerOptions(containerName string, execConfig container.ExecOptions) (string, error) {
128+
L.Info().Strs("Command", execConfig.Cmd).Str("ContainerName", containerName).Msg("Executing command")
118129
ctx := context.Background()
119130
containers, err := dc.cli.ContainerList(ctx, container.ListOptions{
120131
All: true,
@@ -135,11 +146,6 @@ func (dc *DockerClient) ExecContainer(containerName string, command []string) (s
135146
return "", fmt.Errorf("container with name '%s' not found", containerName)
136147
}
137148

138-
execConfig := container.ExecOptions{
139-
Cmd: command,
140-
AttachStdout: true,
141-
AttachStderr: true,
142-
}
143149
execID, err := dc.cli.ContainerExecCreate(ctx, containerID, execConfig)
144150
if err != nil {
145151
return "", fmt.Errorf("failed to create exec instance: %w", err)

framework/examples/myproject/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ require (
138138
github.com/Azure/go-ansiterm v0.0.0-20250102033503-faa5f7b0171c // indirect
139139
github.com/AzureAD/microsoft-authentication-library-for-go v1.3.2 // indirect
140140
github.com/Masterminds/goutils v1.1.1 // indirect
141-
github.com/Masterminds/semver/v3 v3.3.1 // indirect
141+
github.com/Masterminds/semver/v3 v3.4.0 // indirect
142142
github.com/Masterminds/sprig/v3 v3.3.0 // indirect
143143
github.com/Microsoft/go-winio v0.6.2 // indirect
144144
github.com/alecthomas/units v0.0.0-20240927000941-0f3dac36c52b // indirect

framework/examples/myproject/go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ github.com/HdrHistogram/hdrhistogram-go v1.1.2 h1:5IcZpTvzydCQeHzK4Ef/D5rrSqwxob
7272
github.com/HdrHistogram/hdrhistogram-go v1.1.2/go.mod h1:yDgFjdqOqDEKOvasDdhWNXYg9BVp4O+o5f6V/ehm6Oo=
7373
github.com/Masterminds/goutils v1.1.1 h1:5nUrii3FMTL5diU80unEVvNevw1nH4+ZV4DSLVJLSYI=
7474
github.com/Masterminds/goutils v1.1.1/go.mod h1:8cTjp+g8YejhMuvIA5y2vz3BpJxksy863GQaJW2MFNU=
75-
github.com/Masterminds/semver/v3 v3.3.1 h1:QtNSWtVZ3nBfk8mAOu/B6v7FMJ+NHTIgUPi7rj+4nv4=
76-
github.com/Masterminds/semver/v3 v3.3.1/go.mod h1:4V+yj/TJE1HU9XfppCwVMZq3I84lprf4nC11bSS5beM=
75+
github.com/Masterminds/semver/v3 v3.4.0 h1:Zog+i5UMtVoCU8oKka5P7i9q9HgrJeGzI9SA1Xbatp0=
76+
github.com/Masterminds/semver/v3 v3.4.0/go.mod h1:4V+yj/TJE1HU9XfppCwVMZq3I84lprf4nC11bSS5beM=
7777
github.com/Masterminds/sprig/v3 v3.3.0 h1:mQh0Yrg1XPo6vjYXgtf5OtijNAKJRNcTdOOGZe3tPhs=
7878
github.com/Masterminds/sprig/v3 v3.3.0/go.mod h1:Zy1iXRYNqNLUolqCpL4uhk6SHUMAOSCzdgBfDb35Lz0=
7979
github.com/Microsoft/go-winio v0.6.2 h1:F2VQgta7ecxGYO8k3ZZz3RS8fVIXVxONVUPlNERoyfY=

0 commit comments

Comments
 (0)