Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
97 changes: 86 additions & 11 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ test-save-npm-cache: &test-save-npm-cache
- ./node_modules

test-docker-image: &test-docker-image
circleci/node:8.11-stretch-browsers
circleci/node:8.15-stretch-browsers

test-with-oplog: &test-with-oplog
<<: *defaults
Expand All @@ -70,8 +70,8 @@ jobs:
build:
<<: *defaults
docker:
- image: circleci/node:8.11-stretch
- image: mongo:3.2
- image: circleci/node:8.15-stretch
- image: mongo:3.4

steps:
- checkout
Expand Down Expand Up @@ -135,13 +135,15 @@ jobs:
keys:
- meteor-cache-{{ checksum ".circleci/config.yml" }}-{{ checksum ".meteor/versions" }}

- restore_cache:
keys:
- livechat-meteor-cache-{{ checksum ".circleci/config.yml" }}-{{ checksum "packages/rocketchat-livechat/.app/.meteor/versions" }}

- restore_cache:
keys:
- livechat-node-modules-cache-{{ checksum ".circleci/config.yml" }}-{{ checksum "packages/rocketchat-livechat/.app/package.json" }}
# To reduce memory need during actual build, build the packages solely first
- run:
name: Build a Meteor cache
command: |
# to do this we can clear the main files and it build the rest
echo "" > server/main.js
echo "" > client/main.js
meteor build --server-only --debug --directory /tmp/build-temp
git checkout -- server/main.js client/main.js

- run:
name: Build Rocket.Chat
Expand Down Expand Up @@ -236,7 +238,7 @@ jobs:
deploy:
<<: *defaults
docker:
- image: circleci/node:8.11-stretch
- image: circleci/node:8.15-stretch

steps:
- attach_workspace:
Expand Down Expand Up @@ -332,6 +334,79 @@ jobs:
exit 0
fi;

pr-build:
<<: *defaults
docker:
- image: circleci/node:8.15-stretch

steps:
- checkout

- restore_cache:
keys:
- node-modules-cache-{{ checksum ".circleci/config.yml" }}-{{ checksum "package.json" }}

- restore_cache:
keys:
- meteor-{{ checksum ".circleci/config.yml" }}-{{ checksum ".meteor/release" }}

- run:
name: Install Meteor
command: |
# Restore bin from cache
set +e
METEOR_SYMLINK_TARGET=$(readlink ~/.meteor/meteor)
METEOR_TOOL_DIRECTORY=$(dirname "$METEOR_SYMLINK_TARGET")
set -e
LAUNCHER=$HOME/.meteor/$METEOR_TOOL_DIRECTORY/scripts/admin/launch-meteor
if [ -e $LAUNCHER ]
then
echo "Cached Meteor bin found, restoring it"
sudo cp "$LAUNCHER" "/usr/local/bin/meteor"
else
echo "No cached Meteor bin found."
fi

# only install meteor if bin isn't found
command -v meteor >/dev/null 2>&1 || curl https://install.meteor.com | sed s/--progress-bar/-sL/g | /bin/sh

- run:
name: Versions
command: |
npm --versions
node -v
meteor --version
meteor npm --versions
meteor node -v
git version

- run:
name: Meteor npm install
command: |
# rm -rf node_modules
# rm -f package-lock.json
meteor npm install

- restore_cache:
keys:
- meteor-cache-{{ checksum ".circleci/config.yml" }}-{{ checksum ".meteor/versions" }

- run:
name: Build Rocket.Chat
environment:
TOOL_NODE_FLAGS: --max_old_space_size=3072
command: |
meteor build --server-only /tmp/build-pr


- persist_to_workspace:
root: /tmp/
paths:
- build-pr

- store_artifacts:
path: /tmp/build-pr

pr-image-build:
<<: *defaults

Expand Down
36 changes: 17 additions & 19 deletions .meteor/packages
Original file line number Diff line number Diff line change
Expand Up @@ -15,32 +15,31 @@ blaze-html-templates
check@1.3.1
ddp-rate-limiter@1.0.7
ddp-common@1.4.0
dynamic-import@0.5.0
dynamic-import@0.5.1
ecmascript@0.12.4
ejson@1.1.0
email@1.2.3
fastclick@1.0.13
http@1.4.1
http@1.4.2
jquery@1.11.10
logging@1.1.20
meteor-base@1.4.0
mobile-experience@1.0.5
mongo@1.6.0
mongo@1.6.2
random@1.1.0
rate-limit@1.0.9
reactive-dict@1.2.1
reactive-dict@1.3.0
reactive-var@1.0.11
reload@1.2.0
reload@1.3.0
service-configuration@1.0.11
session@1.2.0
shell-server@0.4.0
spacebars
standard-minifier-js@2.4.0
standard-minifier-js@2.4.1
tracker@1.2.0

#rocketchat:google-natural-language
rocketchat:livechat
rocketchat:monitoring
rocketchat:streamer
rocketchat:version

Expand Down Expand Up @@ -80,23 +79,22 @@ littledata:synced-cron

edgee:slingshot
jalik:ufs-local@0.2.5
accounts-base
accounts-oauth
autoupdate
babel-compiler
google-oauth
accounts-base@1.4.3
accounts-oauth@1.1.16
autoupdate@1.6.0
babel-compiler@7.3.4
google-oauth@1.2.6
htmljs
less
matb33:collection-hooks
meteorhacks:inject-initial
oauth
oauth2
oauth@1.2.8
oauth2@1.2.1
raix:eventemitter
routepolicy
sha
swydo:graphql
routepolicy@1.1.0
sha@1.0.9
templating
webapp
webapp-hashing
webapp@1.7.3
webapp-hashing@1.0.9
rocketchat:oauth2-server
rocketchat:i18n
2 changes: 1 addition & 1 deletion .meteor/release
Original file line number Diff line number Diff line change
@@ -1 +1 @@
METEOR@1.8.0.2
METEOR@1.8.1
49 changes: 22 additions & 27 deletions .meteor/versions
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
accounts-base@1.4.3
accounts-base@1.4.4
accounts-facebook@1.3.2
accounts-github@1.4.2
accounts-google@1.3.2
accounts-google@1.3.3
accounts-meteor-developer@1.4.2
accounts-oauth@1.1.16
accounts-password@1.5.1
accounts-twitter@1.4.2
aldeed:simple-schema@1.5.4
allow-deny@1.1.0
autoupdate@1.5.0
babel-compiler@7.2.4
autoupdate@1.6.0
babel-compiler@7.3.4
babel-runtime@1.3.0
base64@1.0.11
base64@1.0.12
binary-heap@1.0.11
blaze@2.3.3
blaze-html-templates@1.1.2
Expand All @@ -28,24 +28,23 @@ ddp@1.4.0
ddp-client@2.3.3
ddp-common@1.4.0
ddp-rate-limiter@1.0.7
ddp-server@2.2.0
ddp-server@2.3.0
deepwell:bootstrap-datepicker2@1.3.0
deps@1.0.12
diff-sequence@1.1.1
dispatch:run-as-user@1.1.1
dynamic-import@0.5.1
ecmascript@0.12.4
ecmascript@0.12.7
ecmascript-runtime@0.7.0
ecmascript-runtime-client@0.8.0
ecmascript-runtime-server@0.7.1
edgee:slingshot@0.7.1
ejson@1.1.0
email@1.2.3
es5-shim@4.8.0
facebook-oauth@1.5.0
facebook-oauth@1.6.0
fastclick@1.0.13
fetch@0.1.0
francocatena:status@1.5.3
fetch@0.1.1
geojson-utils@1.0.10
github-oauth@1.2.2
google-oauth@1.2.6
Expand Down Expand Up @@ -79,24 +78,23 @@ localstorage@1.2.0
logging@1.1.20
matb33:collection-hooks@0.8.4
mdg:validation-error@0.5.1
meteor@1.9.2
meteor@1.9.3
meteor-base@1.4.0
meteor-developer-oauth@1.2.1
meteorhacks:inject-initial@1.0.4
meteorhacks:meteorx@1.4.1
meteorspark:util@0.2.0
minifier-css@1.4.1
minifier-js@2.4.0
minifier-css@1.4.2
minifier-js@2.4.1
minimongo@1.4.5
mizzao:autocomplete@0.5.1
mizzao:timesync@0.3.4
mobile-experience@1.0.5
mobile-status-bar@1.0.14
modern-browsers@0.1.3
modern-browsers@0.1.4
modules@0.13.0
modules-runtime@0.10.3
mongo@1.6.0
mongo-decimal@0.1.0
mongo@1.6.3
mongo-decimal@0.1.1
mongo-dev-server@1.1.0
mongo-id@1.0.7
mongo-livedata@1.0.12
Expand All @@ -105,13 +103,13 @@ mystor:device-detection@0.2.0
nimble:restivus@0.8.12
nooitaf:colors@1.1.2_1
npm-bcrypt@0.9.3
npm-mongo@3.1.1
oauth@1.2.7
npm-mongo@3.1.2
oauth@1.2.8
oauth1@1.2.2
oauth2@1.2.1
observe-sequence@1.0.16
ordered-dict@1.1.0
ostrio:cookies@2.3.0
ostrio:cookies@2.4.0
pauli:accounts-linkedin@5.0.0
pauli:linkedin-oauth@5.0.0
promise@0.11.2
Expand All @@ -121,14 +119,13 @@ raix:handlebar-helpers@0.2.5
raix:ui-dropped-event@0.0.7
random@1.1.0
rate-limit@1.0.9
reactive-dict@1.2.1
reactive-dict@1.3.0
reactive-var@1.0.11
reload@1.2.0
reload@1.3.0
retry@1.1.0
rocketchat:i18n@0.0.1
rocketchat:livechat@0.0.1
rocketchat:mongo-config@0.0.1
rocketchat:monitoring@2.30.2_3
rocketchat:oauth2-server@2.1.0
rocketchat:push@3.3.1
rocketchat:streamer@1.0.2
Expand All @@ -143,9 +140,7 @@ socket-stream-client@0.2.2
spacebars@1.0.15
spacebars-compiler@1.1.3
srp@1.0.12
standard-minifier-js@2.4.0
swydo:graphql@0.4.0
tap:i18n@1.8.2
standard-minifier-js@2.4.1
templating@1.3.2
templating-compiler@1.3.3
templating-runtime@1.3.2
Expand All @@ -157,5 +152,5 @@ twitter-oauth@1.2.0
ui@1.0.13
underscore@1.0.10
url@1.2.0
webapp@1.7.2
webapp@1.7.4
webapp-hashing@1.0.9
2 changes: 1 addition & 1 deletion .snapcraft/resources/preparenode
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

node_version="v8.11.3"
node_version="v8.15.1"

unamem="$(uname -m)"
if [[ $unamem == *aarch64* ]]; then
Expand Down
2 changes: 1 addition & 1 deletion app/assets/server/assets.js
Original file line number Diff line number Diff line change
Expand Up @@ -495,7 +495,7 @@ WebApp.connectHandlers.use('/assets/', Meteor.bindEnvironment(function(req, res,
if (defaultUrl) {
const assetUrl = format && ['png', 'svg'].includes(format) ? defaultUrl.replace(/(svg|png)$/, format) : defaultUrl;
req.url = `/${ assetUrl }`;
WebAppInternals.staticFilesMiddleware(WebAppInternals.staticFiles, req, res, next);
WebAppInternals.staticFilesMiddleware(WebAppInternals.staticFilesByArch, req, res, next);
} else {
res.writeHead(404);
res.end();
Expand Down
Loading