Skip to content

Commit

Permalink
[v2.9] Fix origin of rancher-agent image (rancher#46009)
Browse files Browse the repository at this point in the history
* Fix origin of rancher-agent image, some problems with CGO_ENABLED and tests

Signed-off-by: Guilherme Macedo <[email protected]>
  • Loading branch information
macedogm authored Jul 4, 2024
1 parent edd2985 commit 1d34dbc
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion pkg/api/steve/catalog/plugin_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ func TestProxyRequest_content_type(t *testing.T) {
t.Errorf("got StatusCode %v, want %v", resp.StatusCode, http.StatusOK)
}

wantContent := "application/javascript"
wantContent := "text/javascript; charset=utf-8"
if ct := resp.Header.Get("Content-Type"); ct != wantContent {
t.Errorf("got Content-Type %s, want %s", ct, wantContent)

Expand Down
2 changes: 1 addition & 1 deletion pkg/image/origins.go
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ var OriginMap = map[string]string{
"pushprox-client": "https://github.com/rancher/PushProx",
"pushprox-proxy": "https://github.com/rancher/PushProx",
"rancher": "https://github.com/rancher/rancher",
"rancher-agent": "https://github.com/rancher/rancher-agent",
"rancher-agent": "https://github.com/rancher/rancher",
"rancher-csp-adapter": "https://github.com/rancher/csp-adapter",
"rancher-webhook": "https://github.com/rancher/webhook",
"rke-tools": "https://github.com/rancher/rke-tools",
Expand Down
2 changes: 1 addition & 1 deletion scripts/package
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ fi

if [ ${ARCH} == amd64 ]; then
# Move this out of ARCH check for local dev on non-amd64 hardware.
TAG=$TAG REPO=${REPO} go run ../pkg/image/export/main.go $SYSTEM_CHART_REPO_DIR $CHART_REPO_DIR $IMAGE $AGENT_IMAGE $SYSTEM_AGENT_UPGRADE_IMAGE $WINS_AGENT_UPGRADE_IMAGE ${SYSTEM_AGENT_INSTALLER_RKE2_IMAGES[@]} ${SYSTEM_AGENT_INSTALLER_K3S_IMAGES[@]}
TAG=$TAG REPO=${REPO} CGO_ENABLED=0 go run ../pkg/image/export/main.go $SYSTEM_CHART_REPO_DIR $CHART_REPO_DIR $IMAGE $AGENT_IMAGE $SYSTEM_AGENT_UPGRADE_IMAGE $WINS_AGENT_UPGRADE_IMAGE ${SYSTEM_AGENT_INSTALLER_RKE2_IMAGES[@]} ${SYSTEM_AGENT_INSTALLER_K3S_IMAGES[@]}
fi

# Create components file used for pre-release notes
Expand Down
4 changes: 2 additions & 2 deletions scripts/test
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ fi
cd $(dirname $0)/..

echo Running unit tests
go test -cover -tags=test ./pkg/...
CGO_ENABLED=0 go test -cover -tags=test ./pkg/...

if [ ${ARCH} == arm64 ] || [ ${ARCH} == s390x ]; then
export ETCD_UNSUPPORTED_ARCH=${ARCH}
Expand Down Expand Up @@ -172,7 +172,7 @@ export CATTLE_TEST_CONFIG=$(pwd)/config.yaml # used by integration tests and tes
}

echo Running go integration tests
go test -v -failfast -p 1 ./tests/v2/integration/... || {
CGO_ENABLED=0 go test -v -failfast -p 1 ./tests/v2/integration/... || {
dump_rancher_logs
exit 1
}
Expand Down

0 comments on commit 1d34dbc

Please sign in to comment.