Skip to content

Commit

Permalink
Merge branch 'upstream/release52' into upstream/server-side-notificat…
Browse files Browse the repository at this point in the history
…ions
  • Loading branch information
Julusian committed Dec 11, 2024
2 parents da49fe1 + dd5010a commit b628877
Show file tree
Hide file tree
Showing 351 changed files with 5,786 additions and 12,572 deletions.
4 changes: 1 addition & 3 deletions .github/actions/setup-meteor/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,5 @@ description: "Setup Meteor"
runs:
using: "composite"
steps:
- run: curl "https://install.meteor.com/?release=2.13.3" | sh
shell: bash
- run: meteor npm install -g yarn
- run: curl "https://install.meteor.com/?release=3.1" | sh
shell: bash
4 changes: 2 additions & 2 deletions .github/workflows/audit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
run: |
yarn
cd meteor
meteor npm run validate:prod-dependencies
yarn validate:prod-dependencies
env:
CI: true

Expand Down Expand Up @@ -57,7 +57,7 @@ jobs:
run: |
yarn
cd meteor
meteor npm run validate:all-dependencies
yarn run validate:all-dependencies
env:
CI: true

Expand Down
32 changes: 12 additions & 20 deletions .github/workflows/node.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
# setup zodern:types. No linters are setup, so this simply installs the packages
meteor lint
meteor npm run ci:lint
yarn ci:lint
env:
CI: true

Expand Down Expand Up @@ -85,7 +85,7 @@ jobs:
# setup zodern:types. No linters are setup, so this simply installs the packages
meteor lint
NODE_OPTIONS="--max-old-space-size=6144" meteor npm run unitci --force-exit
NODE_OPTIONS="--max-old-space-size=6144" yarn unitci --force-exit
env:
CI: true
- name: Send coverage
Expand Down Expand Up @@ -480,38 +480,30 @@ jobs:
- blueprints-integration
- server-core-integration
- shared-lib
node-version: [14.x, 18.x, 20.x, 22.x]
- openapi
node-version: [22.x]
include:
# include additional configs, to run certain packages only for a certain version of node
- node-version: 14.x
- node-version: 22.x
package-name: corelib
send-coverage: true
- node-version: 14.x
- node-version: 22.x
package-name: job-worker
send-coverage: true
# manual openapi to avoid testing for 14.x
- node-version: 18.x
package-name: openapi
- node-version: 20.x
package-name: openapi
- node-version: 22.x
package-name: openapi
# No tests for the gateways yet
# - node-version: 18.x
# - node-version: 22.x
# package-name: playout-gateway
# - node-version: 18.x
# - node-version: 22.x
# package-name: mos-gateway
- node-version: 18.x
- node-version: 22.x
package-name: live-status-gateway
send-coverage: true
- node-version: 18.x
- node-version: 22.x
package-name: webui
# manual meteor-lib as it only needs a couple of versions
- node-version: 18.x
- node-version: 22.x
package-name: meteor-lib
send-coverage: true
- node-version: 14.x
package-name: meteor-lib

steps:
- uses: actions/checkout@v4
Expand All @@ -531,7 +523,7 @@ jobs:
run: |
cd packages
yarn config set cacheFolder /home/runner/test-packages-cache
node is_node_14.js && yarn lerna run --ignore openapi install || yarn install
yarn install
yarn lerna run --scope \*\*/${{ matrix.package-name }} --include-dependencies --stream build
env:
CI: true
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/prerelease-libs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
- blueprints-integration
- server-core-integration
- shared-lib
node-version: [14.x, 18.x, 20.x, 22.x]
node-version: [22.x]

steps:
- uses: actions/checkout@v4
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ meteor/.coverage/
node_modules
**/yarn-error.log
scratch/
meteor-settings.json

# Exclude JetBrains IDE specific files
.idea
Expand Down
2 changes: 1 addition & 1 deletion .node-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
18.16
22.11
10 changes: 4 additions & 6 deletions DEVELOPER.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,8 @@ Follow these instructions to start up Sofie Core in development mode. (For produ

### Prerequisites

- Install [Node.js](https://nodejs.org) 14 (using [nvm](https://github.com/nvm-sh/nvm) or [nvm-windows](https://github.com/coreybutler/nvm-windows) is the recommended way to install Node.js)
- Install [Meteor](https://www.meteor.com/install) (`npm install --global meteor@2`)
- Install [Node.js](https://nodejs.org) 18 (using the same method you used above, you can uninstall node 14 if needed)
- Install an older version of corepack (`npm install --global corepack@0.15.3`)
- Install [Node.js](https://nodejs.org) 20 (using [nvm](https://github.com/nvm-sh/nvm) or [nvm-windows](https://github.com/coreybutler/nvm-windows) is the recommended way to install Node.js)
- Install [Meteor](https://www.meteor.com/install) (`npm install --global meteor`)
- Enable [corepack](https://nodejs.org/api/corepack.html#corepack) (`corepack enable`) as administrator/root. If `corepack` is not found, you may need to install it first with `npm install --global corepack`

- If on Windows, you may need to `npm install --global windows-build-tools` but this is not always necessary
Expand Down Expand Up @@ -144,8 +142,8 @@ However, one usage by AdlibActions for their userDataManifest remains as this is

## Blueprint Migrations

In R49, a replacement flow was added consisting of `validateConfig` and `applyConfig`.
It is no longer recommended to use the old migrations flow for showstyle and studio blueprints.
In R52, the replacement flow of `validateConfig` and `applyConfig` was extended to the system blueprint
It is no longer recommended to use the old migrations flow for system blueprints.

### ExpectedMediaItems

Expand Down
1 change: 0 additions & 1 deletion meteor/.eslintignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
.meteor
public
eslint-rules
scripts
server/_force_restart.js
/packages/
3 changes: 1 addition & 2 deletions meteor/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const tmpRules = {
}

const tsBase = {
extends: [...tsExtends, 'plugin:custom-rules/all'],
extends: [...tsExtends],
plugins: tsPlugins,
...tsParser,
settings: {
Expand Down Expand Up @@ -50,7 +50,6 @@ const tsBase = {
allowModules: ['meteor', 'mongodb'],
},
],
'jest/no-standalone-expect': 'off', // testInFiber confuses the rule
...tmpRules,
},
}
Expand Down
18 changes: 7 additions & 11 deletions meteor/.meteor/packages
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,15 @@

# but you can also edit it by hand.

meteor-base@1.5.1 # Packages every Meteor app needs to have
mongo@1.16.10 # The database Meteor supports right now
reactive-var@1.0.12 # Reactive variable for tracker
meteor@2.0.1
webapp@2.0.3
ddp@1.4.2

ecmascript@0.16.8 # Enable ECMAScript2015+ syntax in app code
typescript@4.9.5 # Enable TypeScript syntax in .ts and .tsx modules
shell-server@0.5.0 # Server-side component of the `meteor shell` command
mongo@2.0.2 # The database Meteor supports right now

tracker@1.3.3 # Meteor's client-side reactive programming library
ecmascript@0.16.9 # Enable ECMAScript2015+ syntax in app code
typescript@5.4.3 # Enable TypeScript syntax in .ts and .tsx modules

dynamic-import@0.7.3
ostrio:meteor-root
accounts-password@2.4.0
tracker@1.3.4 # Meteor's client-side reactive programming library

julusian:meteor-elastic-apm@2.5.2
zodern:types
2 changes: 1 addition & 1 deletion meteor/.meteor/release
Original file line number Diff line number Diff line change
@@ -1 +1 @@
METEOR@2.16
METEOR@3.1
114 changes: 49 additions & 65 deletions meteor/.meteor/versions
Original file line number Diff line number Diff line change
@@ -1,65 +1,49 @@
accounts-base@2.2.11
accounts-password@2.4.0
allow-deny@1.1.1
autoupdate@1.8.0
babel-compiler@7.10.5
babel-runtime@1.5.1
base64@1.0.12
binary-heap@1.0.11
boilerplate-generator@1.7.2
callback-hook@1.5.1
check@1.4.1
ddp@1.4.1
ddp-client@2.6.2
ddp-common@1.4.1
ddp-rate-limiter@1.2.1
ddp-server@2.7.1
diff-sequence@1.1.2
dynamic-import@0.7.3
ecmascript@0.16.8
ecmascript-runtime@0.8.1
ecmascript-runtime-client@0.12.1
ecmascript-runtime-server@0.11.0
ejson@1.1.3
email@2.2.6
es5-shim@4.8.0
fetch@0.1.4
geojson-utils@1.0.11
hot-code-push@1.0.4
id-map@1.1.1
inter-process-messaging@0.1.1
julusian:meteor-elastic-apm@2.5.2
kschingiz:meteor-measured@1.0.3
localstorage@1.2.0
logging@1.3.4
meteor@1.11.5
meteor-base@1.5.1
minimongo@1.9.4
modern-browsers@0.1.10
modules@0.20.0
modules-runtime@0.13.1
mongo@1.16.10
mongo-decimal@0.1.3
mongo-dev-server@1.1.0
mongo-id@1.0.8
npm-mongo@4.17.2
ordered-dict@1.1.0
ostrio:meteor-root@1.1.1
promise@0.12.2
random@1.2.1
rate-limit@1.1.1
react-fast-refresh@0.2.8
reactive-var@1.0.12
reload@1.3.1
retry@1.1.0
routepolicy@1.1.1
sha@1.0.9
shell-server@0.5.0
socket-stream-client@0.5.2
tracker@1.3.3
typescript@4.9.5
underscore@1.6.1
url@1.3.2
webapp@1.13.8
webapp-hashing@1.1.1
zodern:types@1.0.9
allow-deny@2.0.0
babel-compiler@7.11.2
babel-runtime@1.5.2
base64@1.0.13
binary-heap@1.0.12
boilerplate-generator@2.0.0
callback-hook@1.6.0
check@1.4.4
core-runtime@1.0.0
ddp@1.4.2
ddp-client@3.0.3
ddp-common@1.4.4
ddp-server@3.0.3
diff-sequence@1.1.3
dynamic-import@0.7.4
ecmascript@0.16.10
ecmascript-runtime@0.8.3
ecmascript-runtime-client@0.12.2
ecmascript-runtime-server@0.11.1
ejson@1.1.4
facts-base@1.0.2
fetch@0.1.5
geojson-utils@1.0.12
id-map@1.2.0
inter-process-messaging@0.1.2
logging@1.3.5
meteor@2.0.2
minimongo@2.0.2
modern-browsers@0.1.11
modules@0.20.3
modules-runtime@0.13.2
mongo@2.0.3
mongo-decimal@0.2.0
mongo-dev-server@1.1.1
mongo-id@1.0.9
npm-mongo@6.10.0
ordered-dict@1.2.0
promise@1.0.0
random@1.2.2
react-fast-refresh@0.2.9
reload@1.3.2
retry@1.1.1
routepolicy@1.1.2
socket-stream-client@0.5.3
tracker@1.3.4
typescript@5.6.3
webapp@2.0.4
webapp-hashing@1.1.2
zodern:types@1.0.13
34 changes: 7 additions & 27 deletions meteor/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# syntax=docker/dockerfile:experimental

# BUILD WEBUI
FROM node:18
FROM node:22
COPY packages /opt/core/packages
WORKDIR /opt/core/packages

Expand All @@ -14,8 +14,8 @@ RUN yarn install && yarn build
# RUN yarn workspaces focus --production @sofie-automation/job-worker @sofie-automation/corelib

# BUILD IMAGE
FROM meteor/node:14.21.4
RUN curl "https://install.meteor.com/?release=2.13.3" | sh
FROM node:22
RUN curl "https://install.meteor.com/?release=3.1" | sh

# Temporary change the NODE_ENV env variable, so that all libraries are installed:
ENV NODE_ENV_TMP $NODE_ENV
Expand All @@ -37,8 +37,8 @@ RUN rm -R /opt/core/packages/webui

# Force meteor to setup the runtime
RUN meteor --version --allow-superuser
RUN meteor corepack enable
RUN meteor yarn install
RUN corepack enable
RUN yarn install

# Restore the NODE_ENV variable:
ENV NODE_ENV $NODE_ENV_TMP
Expand All @@ -50,29 +50,9 @@ RUN npm install
RUN mv /opt/bundle/programs/web.browser/assets /opt/bundle/programs/web.browser/app/assets || true

# DEPLOY IMAGE
FROM alpine:3.19

ENV NODE_VERSION=14.21.4
ENV NODE_URL="https://static.meteor.com/dev-bundle-node-os/unofficial-builds/v${NODE_VERSION}/node-v${NODE_VERSION}-linux-x64.tar.gz"
ENV DIR_NODE=/usr/local

RUN apk add --no-cache \
libstdc++ \
&& apk add --no-cache --virtual .build-deps-full \
binutils-gold \
curl \
gnupg \
xz

RUN echo $NODE_URL \
&& curl -sSL "$NODE_URL" | tar -xz -C /usr/local/ && mv $DIR_NODE/node-v${NODE_VERSION}-linux-x64 $DIR_NODE/v$NODE_VERSION

# add node and npm to path so the commands are available
ENV NODE_PATH $DIR_NODE/v$NODE_VERSION/lib/node_modules
ENV PATH $DIR_NODE/v$NODE_VERSION/bin:$PATH
FROM node:22-alpine

# confirm installation
RUN node -v && npm -v
RUN apk add --no-cache tzdata

COPY --from=1 /opt/bundle /opt/core
COPY meteor/docker-entrypoint.sh /opt
Expand Down
Loading

0 comments on commit b628877

Please sign in to comment.