Skip to content

Commit a479564

Browse files
committed
adding logs for debugging
Signed-off-by: pco <pasquale.convertini@ibm.com>
1 parent 9e15c6f commit a479564

2 files changed

Lines changed: 14 additions & 5 deletions

File tree

.github/workflows/ci.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,14 @@ name: CI
66

77
on:
88
push:
9-
branches: [ "**" ]
9+
branches: ["**"]
1010
pull_request:
11-
branches: [ "**" ]
11+
branches: ["**"]
1212

1313
env:
1414
DB_DEPLOYMENT: local
1515

1616
jobs:
17-
1817
lint:
1918
name: Lint and Build
2019
runs-on: ubuntu-latest
@@ -37,6 +36,12 @@ jobs:
3736
# Fetch main to only show new lint issues.
3837
git fetch -u origin main:main
3938
make lint
39+
# (TODO remove) Debug statements
40+
echo "DEBUG STATEMENTS"
41+
id -u
42+
id -g
43+
ls -la cmd/config/samples
44+
echo "DONE DEBUG STATEMENTS"
4045
4146
- name: Build
4247
run: make build

docker/test/container_release_image_test.go

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,8 @@ func startCommitterNodeWithReleaseImage(ctx context.Context, t *testing.T, param
195195
t.Helper()
196196

197197
configPath := filepath.Join(containerConfigPath, params.node)
198+
containerUser := fmt.Sprintf("%d:%d", os.Getuid(), os.Getgid())
199+
t.Logf("Starting %s as container with user %s.\n", committerReleaseImage, containerUser)
198200
createAndStartContainerAndItsLogs(ctx, t, createAndStartContainerParameters{
199201
config: &container.Config{
200202
Image: committerReleaseImage,
@@ -204,7 +206,7 @@ func startCommitterNodeWithReleaseImage(ctx context.Context, t *testing.T, param
204206
fmt.Sprintf("%s.yaml", configPath),
205207
},
206208
Hostname: params.node,
207-
User: fmt.Sprintf("%d:%d", os.Getuid(), os.Getgid()),
209+
User: containerUser,
208210
Env: []string{
209211
"SC_COORDINATOR_SERVER_TLS_MODE=" + params.tlsMode,
210212
"SC_COORDINATOR_VERIFIER_TLS_MODE=" + params.tlsMode,
@@ -241,6 +243,8 @@ func startLoadgenNodeWithReleaseImage(
241243
t.Helper()
242244

243245
configPath := filepath.Join(containerConfigPath, params.node)
246+
containerUser := fmt.Sprintf("%d:%d", os.Getuid(), os.Getgid())
247+
t.Logf("Starting %s as container with user %s.\n", loadgenReleaseImage, containerUser)
244248
createAndStartContainerAndItsLogs(ctx, t, createAndStartContainerParameters{
245249
config: &container.Config{
246250
Image: loadgenReleaseImage,
@@ -250,7 +254,7 @@ func startLoadgenNodeWithReleaseImage(
250254
fmt.Sprintf("%s.yaml", configPath),
251255
},
252256
Hostname: params.node,
253-
User: fmt.Sprintf("%d:%d", os.Getuid(), os.Getgid()),
257+
User: containerUser,
254258
ExposedPorts: nat.PortSet{
255259
loadGenMetricsPort + "/tcp": {},
256260
},

0 commit comments

Comments
 (0)