Skip to content

Commit

Permalink
Update UI to v0.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
gitlawr authored and guangbochen committed Sep 30, 2020
1 parent a0a3a26 commit d7d4651
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ RUN apk update && apk add -u --no-cache git curl unzip tar tini bash && \

WORKDIR /var/lib/rancher/harvester

ENV HARVESTER_UI_VERSION latest
ENV HARVESTER_UI_VERSION v0.0.1
ENV HARVESTER_UI_PATH /usr/share/rancher/harvester
# Please update the api-ui-version in pkg/settings/settings.go when updating the version here.
ENV HARVESTER_API_UI_VERSION 1.1.9
Expand Down
14 changes: 12 additions & 2 deletions scripts/build
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,18 @@ mkdir -p bin
if [ "$(uname)" = "Linux" ]; then
OTHER_LINKFLAGS="-extldflags -static -s"
fi
LINKFLAGS="-X github.com/rancher/harvester.Version=$VERSION"
LINKFLAGS="-X github.com/rancher/harvester.GitCommit=$COMMIT $LINKFLAGS"

if echo "$VERSION" | grep -q -e '^v.*' ; then
UI_INDEX="local"
fi
UI_INDEX=${UI_INDEX:-"https://releases.rancher.com/harvester-ui/latest/index.html"}

# Inject Setting values
DEFAULT_VALUES="{\"ui-index\":\"${UI_INDEX}\"}"

LINKFLAGS="-X github.com/rancher/harvester.Version=$VERSION
-X github.com/rancher/harvester.GitCommit=$COMMIT
-X github.com/rancher/harvester/pkg/settings.InjectDefaults=$DEFAULT_VALUES $LINKFLAGS"
CGO_ENABLED=0 go build -ldflags "$LINKFLAGS $OTHER_LINKFLAGS" -o bin/harvester
if [ "$CROSS" = "true" ] && [ "$ARCH" = "amd64" ]; then
GOOS=darwin go build -ldflags "$LINKFLAGS" -o bin/harvester-darwin
Expand Down

0 comments on commit d7d4651

Please sign in to comment.