Skip to content

Commit 9c0726b

Browse files
authored
build binary and place it in path
1 parent 43d2d15 commit 9c0726b

1 file changed

Lines changed: 20 additions & 5 deletions

File tree

.github/workflows/kind.yml

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,19 @@ jobs:
2222
go-version: '^1.24'
2323
cache: true
2424

25-
- name: Build
26-
run: go build -v ./...
25+
26+
- name: Build binary app
27+
run: |
28+
# Build with output path specified
29+
go build -v -o basic-docker
30+
31+
# Verify binary exists and is executable
32+
ls -la basic-docker
33+
chmod +x basic-docker
34+
35+
# Move to a directory in PATH (alternative approach)
36+
sudo mv basic-docker /usr/local/bin/
37+
which basic-docker
2738
2839
- name: Create kind cluster
2940
uses: helm/kind-action@v1.5.0
@@ -85,13 +96,17 @@ jobs:
8596
8697
- name: Run capsule attachment tests
8798
run: |
88-
# Run your capsule attachment command with the binary you built
89-
./basic-docker k8s-capsule create test-config 1.0 ./dummy-path
99+
mkdir -p /tmp/capsules
100+
echo "test-config data" > /tmp/capsules/test-config
101+
102+
# Use the binary that should now be in PATH
103+
basic-docker k8s-capsule create test-config 1.0 /tmp/capsules/test-config
90104
91105
# Use kubectl exec to test if capsule is accessible in pod
92106
POD_NAME=$(kubectl get pods -n capsule-test -l app=test-app -o jsonpath="{.items[0].metadata.name}")
93107
94-
# Execute AttachCapsuleToDeployment
108+
# Execute test for AttachCapsuleToDeployment
109+
cd $GITHUB_WORKSPACE
95110
go test -v -run TestAttachCapsuleToDeployment
96111
97112
# Verify that the deployment was updated with the capsule volume

0 commit comments

Comments
 (0)