mirror of
https://github.com/SmartHoneybee/ubiquitous-memory
synced 2025-07-17 09:17:41 +02:00
Update .travis.yml (#23)
This commit is contained in:
parent
9fbbcc9efa
commit
8e48ad9fd6
16
.travis.yml
16
.travis.yml
@ -21,24 +21,32 @@ env:
|
|||||||
- SRCROOT="${GOPATH}/src/github.com/mattermost"
|
- SRCROOT="${GOPATH}/src/github.com/mattermost"
|
||||||
- GOARM=7
|
- GOARM=7
|
||||||
matrix:
|
matrix:
|
||||||
- V=4.7.2
|
- V=4.8.0
|
||||||
before_install:
|
before_install:
|
||||||
- install -d "${GOPATH}" "${GOROOT}" "${SRCROOT}/mattermost-"{server,webapp}
|
- install -d "${GOPATH}" "${GOROOT}" "${SRCROOT}/mattermost-"{server,webapp}
|
||||||
|
# download & extract golang
|
||||||
- wget -q "https://storage.googleapis.com/golang/go${GOV}.linux-amd64.tar.gz"
|
- wget -q "https://storage.googleapis.com/golang/go${GOV}.linux-amd64.tar.gz"
|
||||||
- sha256sum --check <<< "${GOSHA}"
|
- sha256sum --check <<< "${GOSHA}"
|
||||||
- tar -C "${HOME}/${GOV}" -xzf "go${GOV}.linux-amd64.tar.gz"
|
- tar -C "${HOME}/${GOV}" -xzf "go${GOV}.linux-amd64.tar.gz"
|
||||||
|
# set maximum number of open file descriptors
|
||||||
- ulimit -n 8096
|
- ulimit -n 8096
|
||||||
|
# download & extract mattermost-server
|
||||||
- wget -q "https://github.com/mattermost/mattermost-server/archive/v${V}.tar.gz" -O mattermost-server.tar.gz
|
- wget -q "https://github.com/mattermost/mattermost-server/archive/v${V}.tar.gz" -O mattermost-server.tar.gz
|
||||||
- tar -C "${SRCROOT}/mattermost-server" --strip-components=1 -xf mattermost-server.tar.gz
|
- tar -C "${SRCROOT}/mattermost-server" --strip-components=1 -xf mattermost-server.tar.gz
|
||||||
|
# download & extract mattermost-webapp
|
||||||
- wget -q "https://github.com/mattermost/mattermost-webapp/archive/v${V}.tar.gz" -O mattermost-webapp.tar.gz
|
- wget -q "https://github.com/mattermost/mattermost-webapp/archive/v${V}.tar.gz" -O mattermost-webapp.tar.gz
|
||||||
- tar -C "${SRCROOT}/mattermost-webapp" --strip-components=1 -xf mattermost-webapp.tar.gz
|
- tar -C "${SRCROOT}/mattermost-webapp" --strip-components=1 -xf mattermost-webapp.tar.gz
|
||||||
script:
|
script:
|
||||||
- patch -d "${SRCROOT}/mattermost-webapp" -p1 < "${TRAVIS_BUILD_DIR}/webpack.patch"
|
|
||||||
- make build -C "${SRCROOT}/mattermost-webapp"
|
- make build -C "${SRCROOT}/mattermost-webapp"
|
||||||
- patch -d "${SRCROOT}/mattermost-server" -p1 < "${TRAVIS_BUILD_DIR}/make.patch"
|
# workaround (instead of patch): platform binary is in GOOS_GOARCH, Makefile expects it in linux_amd64
|
||||||
|
- install -d "${GOPATH}/bin/linux_amd64"
|
||||||
|
- ln -s "${GOPATH}/bin/linux_arm/platform" "${GOPATH}/bin/linux_amd64/platform"
|
||||||
|
# install dependencies
|
||||||
- go get -d github.com/mattermost/mattermost-server/...
|
- go get -d github.com/mattermost/mattermost-server/...
|
||||||
|
# workaround (instead of patch): overwrite GO variable to enforce desired GOARCH
|
||||||
- make config-reset build-linux package-linux -C "${SRCROOT}/mattermost-server" GO="GOARCH=arm $(which go)" BUILD_NUMBER="dev-arm-tag${V}"
|
- make config-reset build-linux package-linux -C "${SRCROOT}/mattermost-server" GO="GOARCH=arm $(which go)" BUILD_NUMBER="dev-arm-tag${V}"
|
||||||
- mv "${SRCROOT}/mattermost-server/dist/mattermost-team-linux-arm.tar.gz" "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz"
|
# workaround (instead of patch): Makefile creates *-amd64.tar.gz
|
||||||
|
- mv "${SRCROOT}/mattermost-server/dist/mattermost-team-linux-amd64.tar.gz" "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz"
|
||||||
- sha512sum "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz" | tee "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz.sha512sum"
|
- sha512sum "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz" | tee "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz.sha512sum"
|
||||||
deploy:
|
deploy:
|
||||||
provider: releases
|
provider: releases
|
||||||
|
30
make.patch
30
make.patch
@ -1,30 +0,0 @@
|
|||||||
diff --git a/build/release.mk b/build/release.mk
|
|
||||||
index 5eaee80..e0e13bf 100644
|
|
||||||
--- a/build/release.mk
|
|
||||||
+++ b/build/release.mk
|
|
||||||
@@ -59,6 +59,7 @@ endif
|
|
||||||
cp NOTICE.txt $(DIST_PATH)
|
|
||||||
cp README.md $(DIST_PATH)
|
|
||||||
|
|
||||||
+_:
|
|
||||||
@# ----- PLATFORM SPECIFIC -----
|
|
||||||
|
|
||||||
@# Make osx package
|
|
||||||
@@ -85,14 +86,15 @@ endif
|
|
||||||
@# Cleanup
|
|
||||||
rm -f $(DIST_PATH)/bin/platform.exe
|
|
||||||
|
|
||||||
+package-linux: package
|
|
||||||
@# Make linux package
|
|
||||||
@# Copy binary
|
|
||||||
ifeq ($(BUILDER_GOOS_GOARCH),"linux_amd64")
|
|
||||||
cp $(GOPATH)/bin/platform $(DIST_PATH)/bin # from native bin dir, not cross-compiled
|
|
||||||
else
|
|
||||||
- cp $(GOPATH)/bin/linux_amd64/platform $(DIST_PATH)/bin # from cross-compiled bin dir
|
|
||||||
+ cp $(GOPATH)/bin/linux_arm/platform $(DIST_PATH)/bin # from cross-compiled bin dir
|
|
||||||
endif
|
|
||||||
@# Package
|
|
||||||
- tar -C dist -czf $(DIST_PATH)-$(BUILD_TYPE_NAME)-linux-amd64.tar.gz mattermost
|
|
||||||
+ tar -C dist -czf $(DIST_PATH)-$(BUILD_TYPE_NAME)-linux-arm.tar.gz mattermost
|
|
||||||
@# Don't clean up native package so dev machines will have an unzipped package available
|
|
||||||
@#rm -f $(DIST_PATH)/bin/platform
|
|
@ -1,13 +0,0 @@
|
|||||||
diff --git a/package.json b/package.json
|
|
||||||
index d4eabf8..d076a53 100644
|
|
||||||
--- a/package.json
|
|
||||||
+++ b/package.json
|
|
||||||
@@ -146,7 +146,7 @@
|
|
||||||
"scripts": {
|
|
||||||
"check": "eslint --ignore-pattern node_modules --ignore-pattern non_npm_dependencies --ignore-pattern dist --ext .js --ext .jsx . --quiet",
|
|
||||||
"fix": "eslint --ignore-pattern node_modules --ignore-pattern non_npm_dependencies --ignore-pattern dist --ext .js --ext .jsx . --quiet --fix",
|
|
||||||
- "build": "cross-env NODE_ENV=production webpack --display-error-details --verbose --progress",
|
|
||||||
+ "build": "cross-env NODE_ENV=production webpack --display-error-details --progress",
|
|
||||||
"run": "cross-env NODE_ENV=production webpack --progress --watch",
|
|
||||||
"run-fullmap": "webpack --progress --watch",
|
|
||||||
"test": "jest --forceExit",
|
|
Loading…
x
Reference in New Issue
Block a user