Skip to content

Commit

Permalink
arm build
Browse files Browse the repository at this point in the history
  • Loading branch information
xzyaoi committed May 30, 2024
1 parent 0e1d3de commit 124c2a4
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 5 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
examples/
_internal/
Empty file added README.md
Empty file.
7 changes: 3 additions & 4 deletions src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,9 @@ arm: goversion
ifeq (${VERBOSE}, 1)
go env
endif

@mkdir -p ${BUILD_DIR}
GOARCH=arm64 go build ${GOARGS} -trimpath -tags "${GOTAGS}" -ldflags "${LDFLAGS}" -o ${BUILD_DIR}/ ./bin...

GOARCH=arm64 go build ${GOARGS} -trimpath -tags "${GOTAGS}" -ldflags "${LDFLAGS}" -o ${BUILD_DIR} ./bin...
mv ${BUILD_DIR}/bin ${BUILD_DIR}/ocf-arm
@${MAKE} post-build

.PHONY: build
Expand All @@ -94,7 +93,7 @@ endif

@mkdir -p ${BUILD_DIR}
go build ${GOARGS} -trimpath -tags "${GOTAGS}" -ldflags "${LDFLAGS}" -o ${BUILD_DIR} ./bin...
mv ${BUILD_DIR}/bin ${BUILD_DIR}/ocf
mv ${BUILD_DIR}/bin ${BUILD_DIR}/ocf-amd64
@${MAKE} post-build

.PHONY: build-release-deps
Expand Down
1 change: 1 addition & 0 deletions src/internal/protocol/node_table.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ type Service struct {
Name string `json:"name"`
Hardware []HardwareSpec `json:"hardware"`
Status string `json:"status"`
Host string `json:"host"`
Port string `json:"port"`
// IdentityGroup is a list of identities that can access this service
// Format: <identity_group_name>=<identity_name>
Expand Down
2 changes: 1 addition & 1 deletion src/internal/server/proxy_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ func ServiceForwardHandler(c *gin.Context) {
}
target := url.URL{
Scheme: "http",
Host: "127.0.0.1:" + service.Port,
Host: service.Host + ":" + service.Port,
Path: requestPath,
}
director := func(req *http.Request) {
Expand Down

0 comments on commit 124c2a4

Please sign in to comment.