Migrate to pnpm
chore: migrate project to pnpm and update workspace configuration - Added pnpm workspace configuration in pnpm-workspace.yaml to manage packages. - Updated prepare.sh script to use pnpm for installing and building packages. - Modified testapp/package.json scripts to use pnpm instead of npm. - Enhanced tsconfig.client.json and tsconfig.json with additional options and exclusions. - Updated typings README.md to reflect the use of pnpm for installation and building. streamline build process in prepare script and update dependency installation Refactor code structure for improved readability and maintainability refactor: optimize Dockerfile for better layer caching and dependency installation refactor: migrate typings from '@lib/typings/ce' to '@openvidu-meet/typings' - Updated imports across multiple components and services to use the new '@openvidu-meet/typings' package. - Removed legacy typings references and adjusted paths in the frontend and webcomponent projects. - Cleaned up the typings package structure and added build scripts for TypeScript. - Removed the sync-types.sh script as it is no longer needed with the new structure. - Updated README and package.json files to reflect the new package name and structure. feat: add nodemon configuration for API documentation updates and enhance development scripts feat: implement type checking in watch mode and update development scripts feat: enhance development scripts with wait-for-typings and watch-typings utilities fix: remove obsolete sync:backend script and enhance dev script with preserveWatchOutput option feat: enhance development scripts with typings guard and improve watch behavior Refactors build and dev scripts Simplifies and consolidates build and development-related scripts for improved maintainability. - Updates the build process to be more streamlined. - Improves the development workflow by consolidating common tasks. - Removes redundant scripts. Replaces prepare script with meet script Replaces the old `prepare.sh` script with a new `meet.sh` script to provide a more user-friendly and comprehensive interface for building and managing the project. - Integrates command-line arguments for different build targets. - Includes documentation generation for web components and REST APIs. - Provides improved error handling and user feedback. - Simplifies the build process with `pnpm`. chore: update typescript version to 5.9.2 across multiple package.json files refactor: replace constructor injection with inject function for AppDataService feat: add commands to build webcomponent and run unit tests meet.sh: add end-to-end testing support for webcomponent with optional Playwright browser installation chore: update pnpm version to 10 and streamline test commands in workflows meet.sh: rename build_webcomponent_only to build_webcomponent and streamline dependency installation gitignore: add test-results directory to ignore list meet.sh: rename build_webcomponent_only to build_webcomponent for consistency Updated pnpm-lock.yml refactor: streamline build scripts and enhance service start options in meet.sh ci: update OpenVidu Meet actions to use meet-pnpm-migration version refactor: update import paths for WebComponentCommand and WebComponentEvent to use shared typings fix: add moduleNameMapper for typings path in jest configuration fix: correct action version syntax for OpenVidu Meet setup in workflow fix: update typings imports to use shared @openvidu-meet/typings package fix: add skip-install and skip-typings options to meet.sh and update workflows meet.sh: add development mode command and update start services options fix: format code in meeting.component.ts and remove unused export in public-api.ts added openvidu-components-angular to the local workspace and watch for changes in dev mode fix: update Node.js action to v5 and streamline build steps in wc-unit-test.yaml fix: remove pnpm install from build scripts in package.json fix: update backend unit test workflow and add test unit command in meet.sh fix: update unit test command in package.json to use pnpm exec Updates import path for LiveKit permissions Updates the import path for LiveKit permissions to align with the new typings package location, ensuring the test suite remains functional after the project's dependencies are migrated. fix: remove redundant dependency installation and build steps in start_services function fix: update Node.js setup action version and adjust OpenVidu actions for pnpm migration fix: update tsconfig.json to exclude specific type declaration paths fix: remove deprecated dependencies and update openapi-generate-html version fix: update build messages and streamline start commands for production and CI modes fix: update OpenVidu Meet and Testapp actions to use main branch and streamline pre-startup commands Refactors type import for auth mode Updates the import path for the authentication transport mode type. This change ensures consistency across the application by using a centralized type definition. Refactors backend integration tests Streamlines the backend integration test workflow. Consolidates test jobs for better organization and efficiency. Leverages matrix testing for recordings API with different storage providers. Improves AWS runner management for recording tests. Adds artifact cleanup to prevent storage bloat. Sets up Node.js and pnpm Adds Node.js and pnpm setup steps to the integration test workflow. This enables the use of pnpm for managing dependencies during integration tests. Refactors test commands to use pnpm exec Updates the test commands in package.json to use `pnpm exec` for running Jest. This ensures that the Jest CLI is executed within the pnpm managed environment, resolving potential path and dependency issues. Refactors imports to use the new typings package Updates imports to use the new `@openvidu-meet/typings` package. Removes now-unnecessary module name mappings. This change is part of the pnpm migration, ensuring correct resolution of shared types. Enhances backend integration tests and updates Node.js setup Simplifies integration tests execution Updates integration test scripts to streamline execution. - Uses a single, parameterized script to run all backend integration tests. - Removes redundant prefixes from test script names. Refactors jest configuration to include moduleNameMapper for improved module resolution Updates Jest integration test commands to use experimental VM modules and adjusts TypeScript root directory settings for better output structure Ensures OpenVidu Meet logs are uploaded Guarantees OpenVidu Meet logs are uploaded as artifacts, regardless of test outcome. Moves log upload to ensure consistent capture, and does so for all test scenarios. Commented backend integration tests Fix build script to specify TypeScript configuration file Refactor integration test command to use pnpm bin for jest execution Update integration test commands to use relative paths for Jest execution Revert "Commented backend integration tests" This reverts commit 1da8cddb55e29036c2a816244f4bc8b665ede581. Change log upload condition to trigger on failure for OpenVidu Meet logs Add caching step for OpenVidu local deployment images in backend integration tests Revert "Add caching step for OpenVidu local deployment images in backend integration tests" This reverts commit bf4692d168c671100a88c09853a460ec5417979d. Enhance AWS runner setup with storage provider matrix and update job names for clarity Refactor AWS runner setup to separate jobs for S3, ABS, and GCS, enhancing clarity and maintainability Update README.md to enhance structure and clarity, including detailed sections on prerequisites, getting started, development, and documentation. Refactor Dockerfile and entrypoint script, remove deprecated image creation scripts, and enhance meet.sh with Docker build functionality and base href support Update README.md to reflect changes in Docker image build commands using meet.sh Update package.json to correct versioning and remove redundant entries Added browser sync for live reloading chore: update @typescript-eslint packages to version 8.46.1 in frontend and pnpm-lock.yaml fix: correct argument skipping logic and ensure typings are built in install_dependencies function Adapt project structure backend: add TypeScript type annotations for Router instances in route files fix: update path for nodemon configuration in dev:rest-api-docs script fix: update paths in webcomponent documentation generation scripts fix: update Dockerfile and entrypoint script for correct directory structure and improve error handling fix: update .dockerignore and Dockerfile for improved directory handling and permissions; add backend type checker script Added all tests files Updates OpenVidu Meet action refs to main Updates the OpenVidu Meet GitHub Action references in the CI workflows to point to the `main` branch. This ensures that the workflows use the latest version of the action.
This commit is contained in:
parent
6d3329be2a
commit
3d4f04feb1
106
.dockerignore
106
.dockerignore
@ -1,38 +1,36 @@
|
||||
# ====================================================
|
||||
# NODE.JS & NPM
|
||||
# ====================================================
|
||||
**/node_modules/
|
||||
**/npm-debug.log*
|
||||
**/yarn-debug.log*
|
||||
**/yarn-error.log*
|
||||
**/lerna-debug.log*
|
||||
**/.npm
|
||||
**/.pnpm-debug.log*
|
||||
**/**/node_modules/
|
||||
**/**/npm-debug.log*
|
||||
**/**/yarn-debug.log*
|
||||
**/**/yarn-error.log*
|
||||
**/**/lerna-debug.log*
|
||||
**/**/.npm
|
||||
**/**/.pnpm-debug.log*
|
||||
|
||||
# ====================================================
|
||||
# BUILD OUTPUTS & DIST
|
||||
# ====================================================
|
||||
**/dist/
|
||||
**/build/
|
||||
**/coverage/
|
||||
**/.nyc_output/
|
||||
**/lib-cov/
|
||||
**/**/dist/
|
||||
**/**/build/
|
||||
**/**/coverage/
|
||||
**/**/.nyc_output/
|
||||
**/**/lib-cov/
|
||||
|
||||
# # ====================================================
|
||||
# # ANGULAR SPECIFIC
|
||||
# # ====================================================
|
||||
**/.angular/
|
||||
**/**/.angular/
|
||||
|
||||
|
||||
# ====================================================
|
||||
# TESTING & E2E
|
||||
# ====================================================
|
||||
**/e2e/
|
||||
**/tests/screenshots/
|
||||
**/tests/videos/
|
||||
**/tests/results/
|
||||
**/test-results/
|
||||
**/playwright-report/
|
||||
**/**/e2e/
|
||||
**/**/tests/
|
||||
**/**/test-results/
|
||||
**/**/playwright-report/
|
||||
**/test_localstorage_state.json
|
||||
**/*_current.png
|
||||
**/*_mask.png
|
||||
@ -40,8 +38,11 @@
|
||||
**/*.test.js.map
|
||||
**/cypress/
|
||||
**/jest-coverage/
|
||||
**/.jest/
|
||||
**/testapp/
|
||||
**/**/.jest/
|
||||
**/**/jest.*
|
||||
**/**/testapp/
|
||||
**/**/__mocks__/
|
||||
**/**/karma.*
|
||||
|
||||
# ====================================================
|
||||
# DEVELOPMENT TOOLS & EDITORS
|
||||
@ -81,22 +82,23 @@
|
||||
# ====================================================
|
||||
# ENVIRONMENT & CONFIG
|
||||
# ====================================================
|
||||
**/.env
|
||||
**/.env.local
|
||||
**/.env.development.local
|
||||
**/.env.test.local
|
||||
**/.env.production.local
|
||||
**/.env.*.local
|
||||
**/**/.env
|
||||
**/**/.env.local
|
||||
**/**/.env.development.local
|
||||
**/**/.env.test.local
|
||||
**/**/.env.production.local
|
||||
**/**/.env.*.local
|
||||
**/**/nodemon.**
|
||||
|
||||
# ====================================================
|
||||
# DOCUMENTATION & README
|
||||
# ====================================================
|
||||
**/README.md
|
||||
**/CHANGELOG.md
|
||||
**/docs/
|
||||
**/documentation/
|
||||
**/*.md
|
||||
**/webhooks-snippets/
|
||||
**/**/README.md
|
||||
**/**/CHANGELOG.md
|
||||
**/**/docs/
|
||||
**/**/documentation/
|
||||
**/**/*.md
|
||||
**/**/webhooks-snippets/
|
||||
|
||||
# ====================================================
|
||||
# LINTING & FORMATTING
|
||||
@ -125,11 +127,11 @@
|
||||
# ====================================================
|
||||
# CERTIFICATES & KEYS
|
||||
# ====================================================
|
||||
**/*.pem
|
||||
**/*.key
|
||||
**/*.cert
|
||||
**/*.p12
|
||||
**/*.crt
|
||||
**/**/*.pem
|
||||
**/**/*.key
|
||||
**/**/*.cert
|
||||
**/**/*.p12
|
||||
**/**/*.crt
|
||||
|
||||
# ====================================================
|
||||
# MEDIA & ASSETS (Large files)
|
||||
@ -146,32 +148,18 @@
|
||||
# ====================================================
|
||||
# WORKSPACE & PROJECT FILES
|
||||
# ====================================================
|
||||
**/*.code-workspace
|
||||
**/.project
|
||||
**/.classpath
|
||||
**/.settings/
|
||||
|
||||
# ====================================================
|
||||
# CACHE FILES
|
||||
# ====================================================
|
||||
**/.cache/
|
||||
**/cache/
|
||||
**/.parcel-cache/
|
||||
**/.next/
|
||||
**/.nuxt/
|
||||
**/.gatsby/
|
||||
**/**/*.code-workspace
|
||||
|
||||
# ====================================================
|
||||
# BACKEND SPECIFIC
|
||||
# ====================================================
|
||||
**/uploads/
|
||||
**/sessions/
|
||||
**/public/
|
||||
**/**/public/
|
||||
|
||||
# ====================================================
|
||||
# FRONTEND BUILD ARTIFACTS
|
||||
# ====================================================
|
||||
**/webcomponent/dist/
|
||||
**/webcomponent/node_modules/
|
||||
**/frontend/dist/
|
||||
**/frontend/.angular/
|
||||
**/**/node_modules/
|
||||
**/**/*.tgz
|
||||
**/**/webcomponent/dist/
|
||||
**/**/frontend/dist/
|
||||
**/**/frontend/.angular/
|
||||
|
||||
455
.github/workflows/backend-integration-test.yaml
vendored
455
.github/workflows/backend-integration-test.yaml
vendored
@ -4,7 +4,7 @@ on:
|
||||
paths:
|
||||
- 'backend/src/**'
|
||||
- 'backend/package.json'
|
||||
- 'backend/package-lock.json'
|
||||
- 'backend/pnpm-lock.yaml'
|
||||
- 'backend/tests/**'
|
||||
- '.github/workflows/backend-integration-test.yaml'
|
||||
pull_request:
|
||||
@ -30,17 +30,42 @@ jobs:
|
||||
outputs:
|
||||
artifact_name: ${{ steps.build.outputs.artifact_name }}
|
||||
|
||||
test-rooms:
|
||||
name: Rooms API Tests
|
||||
test-api:
|
||||
name: ${{ matrix.test-name }}
|
||||
needs: build-components
|
||||
runs-on: ov-actions-runner
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- test-name: 'Rooms API Tests'
|
||||
test-script: 'test:integration-backend-rooms'
|
||||
- test-name: 'Webhook Tests'
|
||||
test-script: 'test:integration-backend-webhooks'
|
||||
- test-name: 'Security API Tests'
|
||||
test-script: 'test:integration-backend-security'
|
||||
azure-container: 'openvidu-appdata-security'
|
||||
- test-name: 'Global Config API Tests'
|
||||
test-script: 'test:integration-backend-global-config'
|
||||
- test-name: 'Participants API Tests'
|
||||
test-script: 'test:integration-backend-participants'
|
||||
- test-name: 'Meetings API Tests'
|
||||
test-script: 'test:integration-backend-meetings'
|
||||
- test-name: 'Users API Tests'
|
||||
test-script: 'test:integration-backend-users'
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Install LK CLI
|
||||
run: curl -sSL https://get.livekit.io/cli | bash
|
||||
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v5
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v2
|
||||
with:
|
||||
version: 10
|
||||
|
||||
- name: Setup OpenVidu Local Deployment
|
||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
||||
with:
|
||||
@ -54,17 +79,28 @@ jobs:
|
||||
fi
|
||||
BASH
|
||||
chmod +x pre_startup_commands.sh && ./pre_startup_commands.sh
|
||||
|
||||
- name: Setup OpenVidu Meet
|
||||
uses: OpenVidu/actions/start-openvidu-meet@main
|
||||
with:
|
||||
build_components_angular: 'true'
|
||||
components_artifact_name: ${{ needs.build-components.outputs.artifact_name }}
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd backend
|
||||
npm run test:integration-rooms
|
||||
env:
|
||||
JEST_JUNIT_OUTPUT_DIR: './reports/'
|
||||
MEET_AZURE_CONTAINER_NAME: ${{ matrix.azure-container || '' }}
|
||||
|
||||
- name: Run tests
|
||||
run: pnpm run ${{ matrix.test-script }}
|
||||
env:
|
||||
JEST_JUNIT_OUTPUT_DIR: './backend/reports/'
|
||||
|
||||
- name: Upload OpenVidu Meet logs
|
||||
if: failure()
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ matrix.test-name }}-openvidu-meet-logs
|
||||
path: meet_backend.log
|
||||
retention-days: 2
|
||||
|
||||
- name: Publish Test Report
|
||||
uses: mikepenz/action-junit-report@v4
|
||||
if: always()
|
||||
@ -72,290 +108,13 @@ jobs:
|
||||
report_paths: '**/reports/junit.xml'
|
||||
fail_on_failure: true
|
||||
require_tests: true
|
||||
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
test-webhooks:
|
||||
name: Webhook Tests
|
||||
needs: build-components
|
||||
runs-on: ov-actions-runner
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Install LK CLI
|
||||
run: curl -sSL https://get.livekit.io/cli | bash
|
||||
- name: Setup OpenVidu Local Deployment
|
||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
||||
with:
|
||||
ref-openvidu-local-deployment: development
|
||||
pre_startup_commands: |
|
||||
cat <<'BASH' > pre_startup_commands.sh
|
||||
#!/bin/bash
|
||||
echo "Commenting out openvidu-meet container in docker-compose.yaml"
|
||||
if [ -f docker-compose.yaml ]; then
|
||||
yq e 'del(.services.openvidu-meet)' -i docker-compose.yaml
|
||||
fi
|
||||
BASH
|
||||
chmod +x pre_startup_commands.sh && ./pre_startup_commands.sh
|
||||
- name: Setup OpenVidu Meet
|
||||
uses: OpenVidu/actions/start-openvidu-meet@main
|
||||
with:
|
||||
build_components_angular: 'true'
|
||||
components_artifact_name: ${{ needs.build-components.outputs.artifact_name }}
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd backend
|
||||
npm run test:integration-webhooks
|
||||
env:
|
||||
JEST_JUNIT_OUTPUT_DIR: './reports/'
|
||||
- name: Publish Test Report
|
||||
uses: mikepenz/action-junit-report@v4
|
||||
if: always()
|
||||
with:
|
||||
report_paths: '**/reports/junit.xml'
|
||||
fail_on_failure: true
|
||||
require_tests: true
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
test-security:
|
||||
name: Security API Tests
|
||||
needs: build-components
|
||||
runs-on: ov-actions-runner
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Install LK CLI
|
||||
run: curl -sSL https://get.livekit.io/cli | bash
|
||||
- name: Setup OpenVidu Local Deployment
|
||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
||||
with:
|
||||
ref-openvidu-local-deployment: development
|
||||
pre_startup_commands: |
|
||||
cat <<'BASH' > pre_startup_commands.sh
|
||||
#!/bin/bash
|
||||
echo "Commenting out openvidu-meet container in docker-compose.yaml"
|
||||
if [ -f docker-compose.yaml ]; then
|
||||
yq e 'del(.services.openvidu-meet)' -i docker-compose.yaml
|
||||
fi
|
||||
BASH
|
||||
chmod +x pre_startup_commands.sh && ./pre_startup_commands.sh
|
||||
- name: Setup OpenVidu Meet
|
||||
uses: OpenVidu/actions/start-openvidu-meet@main
|
||||
with:
|
||||
build_components_angular: 'true'
|
||||
components_artifact_name: ${{ needs.build-components.outputs.artifact_name }}
|
||||
env:
|
||||
MEET_AZURE_CONTAINER_NAME: 'openvidu-appdata-security'
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd backend
|
||||
npm run test:integration-security
|
||||
env:
|
||||
JEST_JUNIT_OUTPUT_DIR: './reports/'
|
||||
- name: Publish Test Report
|
||||
uses: mikepenz/action-junit-report@v4
|
||||
if: always()
|
||||
with:
|
||||
report_paths: '**/reports/junit.xml'
|
||||
fail_on_failure: true
|
||||
require_tests: true
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
test-global-config:
|
||||
name: Global Config API Tests
|
||||
needs: build-components
|
||||
runs-on: ov-actions-runner
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Install LK CLI
|
||||
run: curl -sSL https://get.livekit.io/cli | bash
|
||||
- name: Setup OpenVidu Local Deployment
|
||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
||||
with:
|
||||
ref-openvidu-local-deployment: development
|
||||
pre_startup_commands: |
|
||||
cat <<'BASH' > pre_startup_commands.sh
|
||||
#!/bin/bash
|
||||
echo "Commenting out openvidu-meet container in docker-compose.yaml"
|
||||
if [ -f docker-compose.yaml ]; then
|
||||
yq e 'del(.services.openvidu-meet)' -i docker-compose.yaml
|
||||
fi
|
||||
BASH
|
||||
chmod +x pre_startup_commands.sh && ./pre_startup_commands.sh
|
||||
- name: Setup OpenVidu Meet
|
||||
uses: OpenVidu/actions/start-openvidu-meet@main
|
||||
with:
|
||||
build_components_angular: 'true'
|
||||
components_artifact_name: ${{ needs.build-components.outputs.artifact_name }}
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd backend
|
||||
npm run test:integration-global-config
|
||||
env:
|
||||
JEST_JUNIT_OUTPUT_DIR: './reports/'
|
||||
- name: Publish Test Report
|
||||
uses: mikepenz/action-junit-report@v4
|
||||
if: always()
|
||||
with:
|
||||
report_paths: '**/reports/junit.xml'
|
||||
fail_on_failure: true
|
||||
require_tests: true
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
test-participants:
|
||||
name: Participants API Tests
|
||||
needs: build-components
|
||||
runs-on: ov-actions-runner
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Install LK CLI
|
||||
run: curl -sSL https://get.livekit.io/cli | bash
|
||||
- name: Setup OpenVidu Local Deployment
|
||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
||||
with:
|
||||
ref-openvidu-local-deployment: development
|
||||
pre_startup_commands: |
|
||||
cat <<'BASH' > pre_startup_commands.sh
|
||||
#!/bin/bash
|
||||
echo "Commenting out openvidu-meet container in docker-compose.yaml"
|
||||
if [ -f docker-compose.yaml ]; then
|
||||
yq e 'del(.services.openvidu-meet)' -i docker-compose.yaml
|
||||
fi
|
||||
BASH
|
||||
chmod +x pre_startup_commands.sh && ./pre_startup_commands.sh
|
||||
- name: Setup OpenVidu Meet
|
||||
uses: OpenVidu/actions/start-openvidu-meet@main
|
||||
with:
|
||||
build_components_angular: 'true'
|
||||
components_artifact_name: ${{ needs.build-components.outputs.artifact_name }}
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd backend
|
||||
npm run test:integration-participants
|
||||
env:
|
||||
JEST_JUNIT_OUTPUT_DIR: './reports/'
|
||||
- name: Publish Test Report
|
||||
uses: mikepenz/action-junit-report@v4
|
||||
if: always()
|
||||
with:
|
||||
report_paths: '**/reports/junit.xml'
|
||||
fail_on_failure: true
|
||||
require_tests: true
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
test-meetings:
|
||||
name: Meetings API Tests
|
||||
needs: build-components
|
||||
runs-on: ov-actions-runner
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Install LK CLI
|
||||
run: curl -sSL https://get.livekit.io/cli | bash
|
||||
- name: Setup OpenVidu Local Deployment
|
||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
||||
with:
|
||||
ref-openvidu-local-deployment: development
|
||||
pre_startup_commands: |
|
||||
cat <<'BASH' > pre_startup_commands.sh
|
||||
#!/bin/bash
|
||||
echo "Commenting out openvidu-meet container in docker-compose.yaml"
|
||||
if [ -f docker-compose.yaml ]; then
|
||||
yq e 'del(.services.openvidu-meet)' -i docker-compose.yaml
|
||||
fi
|
||||
BASH
|
||||
chmod +x pre_startup_commands.sh && ./pre_startup_commands.sh
|
||||
- name: Setup OpenVidu Meet
|
||||
uses: OpenVidu/actions/start-openvidu-meet@main
|
||||
with:
|
||||
build_components_angular: 'true'
|
||||
components_artifact_name: ${{ needs.build-components.outputs.artifact_name }}
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd backend
|
||||
npm run test:integration-meetings
|
||||
env:
|
||||
JEST_JUNIT_OUTPUT_DIR: './reports/'
|
||||
- name: Publish Test Report
|
||||
uses: mikepenz/action-junit-report@v4
|
||||
if: always()
|
||||
with:
|
||||
report_paths: '**/reports/junit.xml'
|
||||
fail_on_failure: true
|
||||
require_tests: true
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
test-users:
|
||||
name: Users API Tests
|
||||
needs: build-components
|
||||
runs-on: ov-actions-runner
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Install LK CLI
|
||||
run: curl -sSL https://get.livekit.io/cli | bash
|
||||
- name: Setup OpenVidu Local Deployment
|
||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
||||
with:
|
||||
ref-openvidu-local-deployment: development
|
||||
pre_startup_commands: |
|
||||
cat <<'BASH' > pre_startup_commands.sh
|
||||
#!/bin/bash
|
||||
echo "Commenting out openvidu-meet container in docker-compose.yaml"
|
||||
if [ -f docker-compose.yaml ]; then
|
||||
yq e 'del(.services.openvidu-meet)' -i docker-compose.yaml
|
||||
fi
|
||||
BASH
|
||||
chmod +x pre_startup_commands.sh && ./pre_startup_commands.sh
|
||||
- name: Setup OpenVidu Meet
|
||||
uses: OpenVidu/actions/start-openvidu-meet@main
|
||||
with:
|
||||
build_components_angular: 'true'
|
||||
components_artifact_name: ${{ needs.build-components.outputs.artifact_name }}
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd backend
|
||||
npm run test:integration-users
|
||||
env:
|
||||
JEST_JUNIT_OUTPUT_DIR: './reports/'
|
||||
- name: Publish Test Report
|
||||
uses: mikepenz/action-junit-report@v4
|
||||
if: always()
|
||||
with:
|
||||
report_paths: '**/reports/junit.xml'
|
||||
fail_on_failure: true
|
||||
require_tests: true
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
start-aws-runner:
|
||||
name: Prepare AWS runner
|
||||
start-aws-runner-s3:
|
||||
name: Prepare AWS runner (S3)
|
||||
runs-on: ov-actions-runner
|
||||
if: ${{ inputs.use-aws != 'false' }}
|
||||
outputs:
|
||||
@ -374,16 +133,64 @@ jobs:
|
||||
ec2-image-id: ${{ vars.AWS_GITHUB_ACTIONS_AMI }}
|
||||
subnet-id: ${{ vars.AWS_SUBNET_ID }}
|
||||
security-group-id: ${{ vars.AWS_SECURITY_GROUP_ID }}
|
||||
workflow-name: ${{ github.workflow }}
|
||||
workflow-name: ${{ github.workflow }}-s3
|
||||
repository-name: ${{ github.repository }}
|
||||
|
||||
start-aws-runner-abs:
|
||||
name: Prepare AWS runner (ABS)
|
||||
runs-on: ov-actions-runner
|
||||
if: ${{ inputs.use-aws != 'false' }}
|
||||
outputs:
|
||||
label: ${{ steps.start-ec2-runner.outputs.label }}
|
||||
ec2-instance-id: ${{ steps.start-ec2-runner.outputs.ec2-instance-id }}
|
||||
steps:
|
||||
- name: Start AWS EC2 Runner
|
||||
id: start-ec2-runner
|
||||
uses: OpenVidu/actions/start-aws-runner@main
|
||||
with:
|
||||
aws-instance-type: ${{ inputs.aws-instance-type || 'c5.2xlarge' }}
|
||||
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
||||
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
||||
aws-region: ${{ vars.AWS_REGION }}
|
||||
github-token: ${{ secrets.OPENVIDU_GITHUB_TOKEN }}
|
||||
ec2-image-id: ${{ vars.AWS_GITHUB_ACTIONS_AMI }}
|
||||
subnet-id: ${{ vars.AWS_SUBNET_ID }}
|
||||
security-group-id: ${{ vars.AWS_SECURITY_GROUP_ID }}
|
||||
workflow-name: ${{ github.workflow }}-abs
|
||||
repository-name: ${{ github.repository }}
|
||||
|
||||
start-aws-runner-gcs:
|
||||
name: Prepare AWS runner (GCS)
|
||||
runs-on: ov-actions-runner
|
||||
if: ${{ inputs.use-aws != 'false' }}
|
||||
outputs:
|
||||
label: ${{ steps.start-ec2-runner.outputs.label }}
|
||||
ec2-instance-id: ${{ steps.start-ec2-runner.outputs.ec2-instance-id }}
|
||||
steps:
|
||||
- name: Start AWS EC2 Runner
|
||||
id: start-ec2-runner
|
||||
uses: OpenVidu/actions/start-aws-runner@main
|
||||
with:
|
||||
aws-instance-type: ${{ inputs.aws-instance-type || 'c5.2xlarge' }}
|
||||
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
||||
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
||||
aws-region: ${{ vars.AWS_REGION }}
|
||||
github-token: ${{ secrets.OPENVIDU_GITHUB_TOKEN }}
|
||||
ec2-image-id: ${{ vars.AWS_GITHUB_ACTIONS_AMI }}
|
||||
subnet-id: ${{ vars.AWS_SUBNET_ID }}
|
||||
security-group-id: ${{ vars.AWS_SECURITY_GROUP_ID }}
|
||||
workflow-name: ${{ github.workflow }}-gcs
|
||||
repository-name: ${{ github.repository }}
|
||||
|
||||
test-recordings:
|
||||
name: Recordings API Tests
|
||||
name: Recordings API Tests (${{ matrix.storage-provider }})
|
||||
needs:
|
||||
- start-aws-runner
|
||||
- start-aws-runner-s3
|
||||
- start-aws-runner-abs
|
||||
- start-aws-runner-gcs
|
||||
- build-components
|
||||
if: ${{ always() && (needs.start-aws-runner.result == 'success' || needs.start-aws-runner.result == 'skipped') }}
|
||||
runs-on: ${{ needs.start-aws-runner.outputs.label || 'ov-actions-runner' }}
|
||||
if: ${{ always() && (needs.start-aws-runner-s3.result == 'success' || needs.start-aws-runner-s3.result == 'skipped') && (needs.start-aws-runner-abs.result == 'success' || needs.start-aws-runner-abs.result == 'skipped') && (needs.start-aws-runner-gcs.result == 'success' || needs.start-aws-runner-gcs.result == 'skipped') }}
|
||||
runs-on: ${{ (matrix.storage-provider == 's3' && needs.start-aws-runner-s3.outputs.label) || (matrix.storage-provider == 'abs' && needs.start-aws-runner-abs.outputs.label) || (matrix.storage-provider == 'gcs' && needs.start-aws-runner-gcs.outputs.label) || 'ov-actions-runner' }}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
@ -391,16 +198,22 @@ jobs:
|
||||
timeout-minutes: 30
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
uses: actions/setup-node@v5
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v2
|
||||
with:
|
||||
version: 10
|
||||
- name: Install LK CLI
|
||||
run: curl -sSL https://get.livekit.io/cli | bash
|
||||
|
||||
- name: Save GCP credentials
|
||||
if: matrix.storage-provider == 'gcs'
|
||||
run: |
|
||||
echo '${{ secrets.GCP_CREDENTIALS_JSON }}' > /tmp/credentials.json
|
||||
chmod 600 /tmp/credentials.json
|
||||
|
||||
- name: Setup OpenVidu Local Deployment
|
||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
||||
with:
|
||||
@ -408,7 +221,7 @@ jobs:
|
||||
pre_startup_commands: |
|
||||
cat <<'BASH' > pre_startup_commands.sh
|
||||
#!/bin/bash
|
||||
if [[ "${{ matrix['storage-provider'] }}" == "abs" ]]; then
|
||||
if [[ "${{ matrix.storage-provider }}" == "abs" ]]; then
|
||||
echo "Using Azure Blob Storage provider"
|
||||
yq e -i '
|
||||
del(.storage.s3) |
|
||||
@ -418,10 +231,10 @@ jobs:
|
||||
"container_name": "openvidu-appdata-recordings"
|
||||
}
|
||||
' egress.yaml
|
||||
elif [[ "${{ matrix['storage-provider'] }}" == "gcs" ]]; then
|
||||
elif [[ "${{ matrix.storage-provider }}" == "gcs" ]]; then
|
||||
echo "Using Google Cloud Storage provider"
|
||||
yq eval --inplace '.storage.gcp.credentials_json = (load("/tmp/credentials.json") | tostring) | .storage.gcp.credentials_json style="single"' egress.yaml
|
||||
|
||||
|
||||
yq e -i '
|
||||
del(.storage.s3) |
|
||||
.storage.gcp.bucket = "openvidu-appdata"
|
||||
@ -434,6 +247,7 @@ jobs:
|
||||
fi
|
||||
BASH
|
||||
chmod +x pre_startup_commands.sh && ./pre_startup_commands.sh
|
||||
|
||||
- name: Setup OpenVidu Meet
|
||||
uses: OpenVidu/actions/start-openvidu-meet@main
|
||||
with:
|
||||
@ -448,12 +262,11 @@ jobs:
|
||||
# GCS variables
|
||||
GOOGLE_APPLICATION_CREDENTIALS: ${{ matrix.storage-provider == 'gcs' && '/tmp/credentials.json' || '' }}
|
||||
MEET_S3_BUCKET: ${{ matrix.storage-provider == 'gcs' && 'openvidu-appdata' || 'openvidu-appdata' }}
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd backend
|
||||
npm run test:integration-recordings
|
||||
run: pnpm run test:integration-backend-recordings
|
||||
env:
|
||||
JEST_JUNIT_OUTPUT_DIR: './reports/'
|
||||
JEST_JUNIT_OUTPUT_DIR: './backend/reports/'
|
||||
MEET_BLOB_STORAGE_MODE: ${{ matrix.storage-provider }}
|
||||
# ABS variables
|
||||
MEET_AZURE_ACCOUNT_NAME: ${{ matrix.storage-provider == 'abs' && vars.MEET_AZURE_ACCOUNT_NAME || '' }}
|
||||
@ -462,6 +275,7 @@ jobs:
|
||||
# GCS variables
|
||||
GOOGLE_APPLICATION_CREDENTIALS: ${{ matrix.storage-provider == 'gcs' && '/tmp/credentials.json' || '' }}
|
||||
MEET_S3_BUCKET: ${{ matrix.storage-provider == 'gcs' && 'openvidu-appdata' || 'openvidu-appdata' }}
|
||||
|
||||
- name: Publish Test Report
|
||||
uses: mikepenz/action-junit-report@v4
|
||||
if: always()
|
||||
@ -469,52 +283,55 @@ jobs:
|
||||
report_paths: '**/reports/junit.xml'
|
||||
fail_on_failure: true
|
||||
require_tests: true
|
||||
- name: Upload OpenVidu Meet logs on failure
|
||||
|
||||
- name: Upload OpenVidu Meet logs
|
||||
if: failure()
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: recordings-test-${{ matrix.storage-provider }}-openvidu-meet-logs
|
||||
path: backend/meet_backend.log
|
||||
retention-days: 2
|
||||
|
||||
- name: Clean up credentials
|
||||
if: always() && matrix.storage-provider == 'gcs'
|
||||
run: |
|
||||
rm -f /tmp/credentials.json
|
||||
echo "GCP credentials file removed"
|
||||
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
stop-runner:
|
||||
name: Stop EC2 runner
|
||||
name: Stop EC2 runner (${{ matrix.storage-provider }})
|
||||
needs:
|
||||
- start-aws-runner
|
||||
- start-aws-runner-s3
|
||||
- start-aws-runner-abs
|
||||
- start-aws-runner-gcs
|
||||
- test-recordings
|
||||
runs-on: ov-actions-runner
|
||||
if: ${{ always() && needs.start-aws-runner.outputs.label != '' }}
|
||||
if: ${{ always() }}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
storage-provider: [s3, abs, gcs]
|
||||
steps:
|
||||
- name: Stop AWS EC2 Runner
|
||||
id: stop-ec2-runner
|
||||
if: ${{ (matrix.storage-provider == 's3' && needs.start-aws-runner-s3.result != 'skipped') || (matrix.storage-provider == 'abs' && needs.start-aws-runner-abs.result != 'skipped') || (matrix.storage-provider == 'gcs' && needs.start-aws-runner-gcs.result != 'skipped') }}
|
||||
uses: OpenVidu/actions/stop-aws-runner@main
|
||||
with:
|
||||
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
||||
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
||||
aws-region: ${{ vars.AWS_REGION }}
|
||||
github-token: ${{ secrets.OPENVIDU_GITHUB_TOKEN }}
|
||||
label: ${{ needs.start-aws-runner.outputs.label }}
|
||||
ec2-instance-id: ${{ needs.start-aws-runner.outputs.ec2-instance-id }}
|
||||
label: ${{ (matrix.storage-provider == 's3' && needs.start-aws-runner-s3.outputs.label) || (matrix.storage-provider == 'abs' && needs.start-aws-runner-abs.outputs.label) || (matrix.storage-provider == 'gcs' && needs.start-aws-runner-gcs.outputs.label) }}
|
||||
ec2-instance-id: ${{ (matrix.storage-provider == 's3' && needs.start-aws-runner-s3.outputs.ec2-instance-id) || (matrix.storage-provider == 'abs' && needs.start-aws-runner-abs.outputs.ec2-instance-id) || (matrix.storage-provider == 'gcs' && needs.start-aws-runner-gcs.outputs.ec2-instance-id) }}
|
||||
|
||||
remove-components-artifact:
|
||||
name: Remove OpenVidu Components Angular Artifact
|
||||
needs:
|
||||
- build-components
|
||||
- test-rooms
|
||||
- test-webhooks
|
||||
- test-security
|
||||
- test-global-config
|
||||
- test-participants
|
||||
- test-meetings
|
||||
- test-users
|
||||
- test-api
|
||||
- test-recordings
|
||||
runs-on: ov-actions-runner
|
||||
if: ${{ always() }}
|
||||
|
||||
24
.github/workflows/backend-unit-test.yaml
vendored
24
.github/workflows/backend-unit-test.yaml
vendored
@ -10,20 +10,27 @@ jobs:
|
||||
runs-on: ov-actions-runner
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
uses: actions/setup-node@v5
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4
|
||||
with:
|
||||
version: 10
|
||||
- name: Checkout OpenVidu Meet
|
||||
uses: actions/checkout@v4
|
||||
- name: Setup OpenVidu Meet Backend
|
||||
shell: bash
|
||||
run: ./prepare.sh --typings --backend
|
||||
|
||||
- name: Install dependencies
|
||||
run: ./meet.sh install
|
||||
|
||||
- name: Build typings
|
||||
run: ./meet.sh build-typings --skip-install
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd backend
|
||||
npm run test:unit
|
||||
run: ./meet.sh test-unit-backend --skip-install
|
||||
env:
|
||||
JEST_JUNIT_OUTPUT_DIR: './reports/'
|
||||
JEST_JUNIT_OUTPUT_DIR: './backend/reports/'
|
||||
|
||||
- name: Publish Test Report
|
||||
uses: mikepenz/action-junit-report@v4
|
||||
if: always()
|
||||
@ -31,6 +38,7 @@ jobs:
|
||||
report_paths: '**/reports/junit.xml'
|
||||
fail_on_failure: true
|
||||
require_tests: true
|
||||
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
25
.github/workflows/wc-e2e-test.yaml
vendored
25
.github/workflows/wc-e2e-test.yaml
vendored
@ -10,9 +10,13 @@ jobs:
|
||||
runs-on: ov-actions-runner
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
uses: actions/setup-node@v5
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4
|
||||
with:
|
||||
version: 10
|
||||
- name: Setup OpenVidu Local Deployment
|
||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
||||
with:
|
||||
@ -26,25 +30,27 @@ jobs:
|
||||
fi
|
||||
BASH
|
||||
chmod +x pre_startup_commands.sh && ./pre_startup_commands.sh
|
||||
- name: Setup OpenVidu Meet
|
||||
|
||||
- name: Build and Start OpenVidu Meet
|
||||
uses: OpenVidu/actions/start-openvidu-meet@main
|
||||
env:
|
||||
MEET_INITIAL_WEBHOOK_ENABLED: true
|
||||
MEET_INITIAL_WEBHOOK_URL: 'http://localhost:5080/webhook'
|
||||
|
||||
- name: Start OpenVidu Meet Testapp
|
||||
uses: OpenVidu/actions/start-openvidu-meet-testapp@main
|
||||
with:
|
||||
skip_install: 'true'
|
||||
skip_checkout: 'true'
|
||||
skip_build_typings: 'true'
|
||||
skip_build_webcomponent: 'true'
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd frontend/webcomponent
|
||||
# Install Playwright browsers
|
||||
mkdir -p /tmp/ms-playwright
|
||||
npx playwright install --with-deps chromium
|
||||
npm run test:e2e
|
||||
run: ./meet.sh test-e2e-webcomponent --skip-install
|
||||
env:
|
||||
RUN_MODE: CI
|
||||
PLAYWRIGHT_BROWSERS_PATH: /tmp/ms-playwright
|
||||
|
||||
- name: Upload test results
|
||||
if: always()
|
||||
uses: actions/upload-artifact@v4
|
||||
@ -52,6 +58,7 @@ jobs:
|
||||
name: room-test-results
|
||||
path: frontend/webcomponent/test-results/
|
||||
retention-days: 2
|
||||
|
||||
- name: Upload TestApp logs on failure
|
||||
if: failure()
|
||||
uses: actions/upload-artifact@v4
|
||||
@ -59,6 +66,7 @@ jobs:
|
||||
name: room-test-testapp-logs
|
||||
path: testapp/testapp.log
|
||||
retention-days: 2
|
||||
|
||||
- name: Upload OpenVidu Meet logs on failure
|
||||
if: failure()
|
||||
uses: actions/upload-artifact@v4
|
||||
@ -66,6 +74,7 @@ jobs:
|
||||
name: room-test-openvidu-meet-logs
|
||||
path: backend/meet_backend.log
|
||||
retention-days: 2
|
||||
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
24
.github/workflows/wc-unit-test.yaml
vendored
24
.github/workflows/wc-unit-test.yaml
vendored
@ -10,18 +10,28 @@ jobs:
|
||||
runs-on: ov-actions-runner
|
||||
steps:
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
uses: actions/setup-node@v5
|
||||
with:
|
||||
node-version: '22.13'
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4
|
||||
with:
|
||||
version: 10
|
||||
- name: Checkout OpenVidu Meet
|
||||
uses: actions/checkout@v4
|
||||
- name: Setup OpenVidu Meet WebComponent
|
||||
shell: bash
|
||||
run: ./prepare.sh --typings --webcomponent
|
||||
|
||||
- name: Install dependencies
|
||||
run: ./meet.sh install
|
||||
|
||||
- name: Build typings
|
||||
run: ./meet.sh build-typings --skip-install
|
||||
|
||||
- name: Build webcomponent
|
||||
run: ./meet.sh build-webcomponent --skip-install --skip-typings
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd frontend/webcomponent
|
||||
npm run test:unit
|
||||
run: ./meet.sh test-unit-webcomponent --skip-install
|
||||
|
||||
- name: Clean up
|
||||
if: always()
|
||||
uses: OpenVidu/actions/cleanup@main
|
||||
|
||||
50
.gitignore
vendored
50
.gitignore
vendored
@ -1,20 +1,22 @@
|
||||
# See http://help.github.com/ignore-files/ for more about ignoring files.
|
||||
|
||||
# compiled output
|
||||
*.angular
|
||||
**/dist
|
||||
**/**/*.angular
|
||||
**/**/dist
|
||||
/tmp
|
||||
/out-tsc
|
||||
*.tgz
|
||||
**/**/*.tgz
|
||||
|
||||
|
||||
# dependencies
|
||||
**/*/node_modules
|
||||
**/*/target
|
||||
**/**/node_modules
|
||||
**/**/target
|
||||
|
||||
# pnpm
|
||||
.pnpm-store
|
||||
.pnpm-debug.log
|
||||
pnpm-debug.log*
|
||||
|
||||
# profiling files
|
||||
chrome-profiler-events*.json
|
||||
speed-measure-plugin*.json
|
||||
|
||||
# IDEs and editors
|
||||
/.idea
|
||||
@ -28,37 +30,19 @@ speed-measure-plugin*.json
|
||||
# IDE - VSCode
|
||||
.history/*
|
||||
|
||||
# misc
|
||||
/.sass-cache
|
||||
/connect.lock
|
||||
/coverage
|
||||
/libpeerconnection.log
|
||||
npm-debug.log
|
||||
yarn-error.log
|
||||
testem.log
|
||||
./**/typings
|
||||
|
||||
# System Files
|
||||
.DS_Store
|
||||
Thumbs.db
|
||||
|
||||
.editorconfig
|
||||
*.browserslistrc
|
||||
.git/*
|
||||
|
||||
|
||||
backend/public/
|
||||
**/**/test-results
|
||||
**/**/public/
|
||||
|
||||
frontend/projects/shared-meet-components/src/lib/typings/
|
||||
|
||||
backend/src/typings/
|
||||
**/*/coverage
|
||||
**/**/test-results
|
||||
**/**/openvidu-meet.**.js
|
||||
|
||||
frontend/webcomponent/**/openvidu-meet.**.js
|
||||
testapp/public/js/app.js
|
||||
testapp/public/js/webcomponent.js
|
||||
frontend/webcomponent/test-results/.last-run.json
|
||||
frontend/webcomponent/test_localstorage_state.json
|
||||
|
||||
**test-results/**
|
||||
frontend/webcomponent/src/typings/
|
||||
**/**/docs/webcomponent-attributes.md
|
||||
**/**/docs/webcomponent-commands.md
|
||||
**/**/docs/webcomponent-events.md
|
||||
|
||||
17
.npmrc
Normal file
17
.npmrc
Normal file
@ -0,0 +1,17 @@
|
||||
# Strict peer dependencies
|
||||
strict-peer-dependencies=false
|
||||
|
||||
# Auto install peers
|
||||
auto-install-peers=true
|
||||
|
||||
# Shamefully hoist - neccessary for some packages
|
||||
shamefully-hoist=true
|
||||
|
||||
# Node linker - use hoisted for full compatibility
|
||||
node-linker=hoisted
|
||||
|
||||
# Lockfile settings
|
||||
lockfile=true
|
||||
|
||||
# Optional: Store location (uncomment if you want to customize)
|
||||
# store-dir=.pnpm-store
|
||||
399
README.md
399
README.md
@ -1,128 +1,233 @@
|
||||
# OpenVidu Meet
|
||||
|
||||
OpenVidu Meet is a fully featured video conferencing application built with Angular, Node.js, and LiveKit. This repository provides both a Community Edition (CE) and a Professional Edition (PRO) with advanced features.
|
||||
|
||||
# Table of Contents
|
||||
|
||||
1. [Architecture Overview](#architecture-overview)
|
||||
2. [Development](#development)
|
||||
- [1. Clone the Repository](#1-clone-the-openvidu-meet-repository)
|
||||
- [2. Prepare the Project](#2-prepare-the-project)
|
||||
- [3. Start the Backend](#3-start-the-backend)
|
||||
- [4. Start the Frontend](#4-start-the-frontend)
|
||||
3. [Testing](#testing)
|
||||
4. [Build (with Docker)](#build-with-docker)
|
||||
- [Build the Backend Image](#build-the-backend-image)
|
||||
- [Run the Backend Container](#run-the-backend-container)
|
||||
2. [Prerequisites](#prerequisites)
|
||||
3. [Getting Started](#getting-started)
|
||||
4. [Development](#development)
|
||||
- [Development Mode](#development-mode)
|
||||
- [Manual Development Setup](#manual-development-setup)
|
||||
5. [Building](#building)
|
||||
6. [Testing](#testing)
|
||||
7. [Documentation](#documentation)
|
||||
8. [Production Deployment](#production-deployment)
|
||||
9. [Project Structure](#project-structure)
|
||||
10. [Using the meet.sh Script](#using-the-meetsh-script)
|
||||
|
||||
## Architecture Overview
|
||||
|
||||
The OpenVidu Meet application is composed of two main parts (frontend and backend) that interact with each other to provide the video conferencing service. The following diagram illustrates the architecture of the application:
|
||||
The OpenVidu Meet application is a monorepo managed with **pnpm workspaces** and consists of multiple interconnected packages:
|
||||
|
||||
[](/docs/openvidu-meet-ce-architecture.png)
|
||||
|
||||
- **Frontend**: The frontend is a web application built with Angular that provides the user interface for the video conferencing service. This project contains the **shared-meet-components** subproject, which is a library of shared components that share administration and preference components.
|
||||
### Core Components
|
||||
|
||||
Also, the frontend project installs external dependencies on the following libraries:
|
||||
- **Frontend** (`frontend/`): Angular 20 application providing the user interface
|
||||
- **shared-meet-components**: Reusable Angular library with shared components for administration and preferences
|
||||
- Integrates [openvidu-components-angular](https://github.com/OpenVidu/openvidu/tree/master/openvidu-components-angular) for core video conferencing functionality
|
||||
|
||||
- [**openvidu-components-angular**](https://github.com/OpenVidu/openvidu/tree/master/openvidu-components-angular): A library of Angular components that provide the core functionality of the video conferencing service.
|
||||
- [**typings**](./typings/): Common types used by the frontend and backend.
|
||||
- **Backend** (`backend/`): Node.js/TypeScript REST API server
|
||||
- Manages rooms, participants, recordings, and authentication
|
||||
- Serves the compiled frontend in production
|
||||
|
||||
- **Backend**: The backend is a Node.js application.
|
||||
- [**typings**](./typings/): Common types used by the frontend and backend.
|
||||
- **Typings** (`typings/`): Shared TypeScript type definitions used across frontend and backend
|
||||
|
||||
- **Webcomponent** (`frontend/webcomponent/`): Standalone web component version of OpenVidu Meet
|
||||
|
||||
- **TestApp** (`testapp/`): Testing application for development and validation
|
||||
|
||||
## Prerequisites
|
||||
|
||||
Before starting, ensure you have the following installed:
|
||||
|
||||
- **Node.js**: Version 22 or higher
|
||||
- **pnpm**: Package manager (will be installed automatically by meet.sh if missing)
|
||||
- **LiveKit**: For local testing (optional)
|
||||
```bash
|
||||
curl -sSL https://get.livekit.io/cli | bash
|
||||
```
|
||||
|
||||
## Getting Started
|
||||
|
||||
The simplest way to get started is using the `meet.sh` script:
|
||||
|
||||
```bash
|
||||
# Clone the repository
|
||||
git clone https://github.com/OpenVidu/openvidu-meet.git
|
||||
cd openvidu-meet
|
||||
|
||||
# Install all dependencies
|
||||
./meet.sh install
|
||||
|
||||
# Start development mode with hot-reload
|
||||
./meet.sh dev
|
||||
```
|
||||
|
||||
Access the application at [http://localhost:6080](http://localhost:6080)
|
||||
|
||||
## Development
|
||||
|
||||
For development purposes, you can run the application locally by following the instructions below.
|
||||
### Development Mode
|
||||
|
||||
**1. Clone the OpenVidu Meet repository:**
|
||||
The recommended way to develop is using the integrated development mode that watches all components:
|
||||
|
||||
```bash
|
||||
git clone https://github.com/OpenVidu/openvidu-meet.git
|
||||
./meet.sh dev
|
||||
```
|
||||
|
||||
**2. Prepare the project**
|
||||
|
||||
For building types and install dependencies, run the following command:
|
||||
|
||||
```bash
|
||||
cd openvidu-meet
|
||||
./prepare.sh
|
||||
```
|
||||
|
||||
**3. Start the Backend**
|
||||
This command starts concurrent watchers for:
|
||||
- **openvidu-components-angular**: Core Angular components library
|
||||
- **Typings**: Shared type definitions with automatic sync
|
||||
- **Backend**: Node.js server with nodemon auto-restart
|
||||
- **Frontend**: Angular application with live reload
|
||||
- **REST API Docs**: OpenAPI documentation generation
|
||||
|
||||
> [!NOTE]
|
||||
> For development purposes, the backend application uses the `backend/.env.development` file to load environment variables. You can customize the values in this file to suit your local development environment.
|
||||
> The backend uses `backend/.env.development` for environment variables during development. Configure your LiveKit credentials there:
|
||||
> ```env
|
||||
> LIVEKIT_URL=ws://localhost:7880
|
||||
> LIVEKIT_API_KEY=your-api-key
|
||||
> LIVEKIT_API_SECRET=your-api-secret
|
||||
> ```
|
||||
|
||||
### Manual Development Setup
|
||||
|
||||
If you prefer more granular control:
|
||||
|
||||
```bash
|
||||
cd backend && \
|
||||
npm run start:dev
|
||||
# Install dependencies
|
||||
./meet.sh install
|
||||
|
||||
# Build shared typings (required first)
|
||||
./meet.sh build-typings
|
||||
|
||||
# In separate terminals:
|
||||
# Terminal 1 - Backend
|
||||
cd backend
|
||||
pnpm run start:dev
|
||||
|
||||
# Terminal 2 - Frontend
|
||||
cd frontend
|
||||
pnpm run dev
|
||||
|
||||
# Terminal 3 - Typings watcher (optional)
|
||||
cd typings
|
||||
pnpm run dev
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> **The types under `typings` are shared between the frontend and backend projects.**
|
||||
> If you need to update the comon types, remember doing it in the `typings` project.
|
||||
>
|
||||
> Every time you make changes to the types, the backend process will automatically invoke the syncing task to update the types in the frontend and backend projects. So, you don't need to worry about updating the types manually.
|
||||
> [!IMPORTANT]
|
||||
> **Shared Typings**: The `typings/` package contains types shared between frontend and backend. When you modify these types in development mode, they are automatically synced to both projects. Always build typings before building other components.
|
||||
|
||||
**4. Start the Frontend**
|
||||
## Building
|
||||
|
||||
Opening a new tab, under root directory:
|
||||
Build all components in the correct order:
|
||||
|
||||
```bash
|
||||
cd frontend && \
|
||||
npm run build:dev
|
||||
# Build everything (typings → frontend → backend → webcomponent)
|
||||
./meet.sh build
|
||||
|
||||
# Or build individual components:
|
||||
./meet.sh build-typings # Build shared types
|
||||
./meet.sh build-webcomponent # Build web component only
|
||||
./meet.sh build-testapp # Build test application
|
||||
```
|
||||
|
||||
This command will build the frontend application and move the files to the backend project. It will also listen for changes in the frontend application and rebuild the application when changes are detected.
|
||||
### CI/CD Optimized Builds
|
||||
|
||||
After running these commands, you can access the frontend application at [http://localhost:6080](http://localhost:6080).
|
||||
The `meet.sh` script supports flags to optimize CI/CD pipelines:
|
||||
|
||||
```bash
|
||||
# Install dependencies once
|
||||
./meet.sh install
|
||||
|
||||
# Build typings once
|
||||
./meet.sh build-typings
|
||||
|
||||
# Build webcomponent (skip already completed steps)
|
||||
./meet.sh build-webcomponent --skip-install --skip-typings
|
||||
|
||||
# Run tests without reinstalling
|
||||
./meet.sh test-unit-webcomponent --skip-install
|
||||
```
|
||||
|
||||
**Available flags:**
|
||||
- `--skip-install`: Skip dependency installation
|
||||
- `--skip-build`: Skip build steps
|
||||
- `--skip-typings`: Skip typings build (use when already built)
|
||||
|
||||
## Testing
|
||||
|
||||
This repository offers a testing application that allows you to test the OpenVidu Meet.
|
||||
OpenVidu Meet includes comprehensive testing capabilities:
|
||||
|
||||
### Pre-requisites
|
||||
|
||||
To run the testing application, you need to have the following pre-requisites installed:
|
||||
|
||||
- [Node.js](https://nodejs.org/en/download/) (version 22 or higher)
|
||||
- LiveKit CLI installed and configured.
|
||||
### Unit Tests
|
||||
|
||||
```bash
|
||||
curl -sSL https://get.livekit.io/cli | bash
|
||||
# Backend unit tests
|
||||
./meet.sh test-unit-backend
|
||||
|
||||
# Webcomponent unit tests
|
||||
./meet.sh test-unit-webcomponent
|
||||
```
|
||||
|
||||
To run the testing application, follow these steps under the root directory:
|
||||
|
||||
1. Install the dependencies:
|
||||
### End-to-End Tests
|
||||
|
||||
```bash
|
||||
cd testapp && \
|
||||
npm install
|
||||
# Run E2E tests for webcomponent (installs Playwright automatically)
|
||||
./meet.sh test-e2e-webcomponent
|
||||
|
||||
# Force reinstall Playwright browsers
|
||||
./meet.sh test-e2e-webcomponent --force-install
|
||||
```
|
||||
|
||||
2. Start the testing application:
|
||||
### TestApp
|
||||
|
||||
The repository includes a dedicated testing application for manual testing:
|
||||
|
||||
```bash
|
||||
npm run start
|
||||
# Build and start the test application
|
||||
./meet.sh start-testapp
|
||||
```
|
||||
|
||||
After running these commands, you can access the testing application at [http://localhost:5080](http://localhost:5080).
|
||||
The test app will be available at [http://localhost:5080](http://localhost:5080)
|
||||
|
||||
## Build (with docker)
|
||||
> [!NOTE]
|
||||
> The TestApp requires LiveKit CLI to be installed and configured for full functionality.
|
||||
|
||||
### Build the backend image
|
||||
## Documentation
|
||||
|
||||
### Generate Documentation
|
||||
|
||||
```bash
|
||||
cd docker
|
||||
./create_image.sh openvidu-meet-ce
|
||||
# Generate webcomponent documentation
|
||||
./meet.sh build-webcomponent-doc [output_dir]
|
||||
|
||||
# Generate REST API documentation
|
||||
./meet.sh build-rest-api-doc [output_dir]
|
||||
```
|
||||
|
||||
### Run the backend container
|
||||
Documentation files will be generated in:
|
||||
- **Webcomponent**: `docs/webcomponent-*.md` (events, commands, attributes)
|
||||
- **REST API**: `backend/public/openapi/public.html`
|
||||
|
||||
Once the image is created, you can run the container with the following command:
|
||||
If you specify an output directory, the documentation will be copied there.
|
||||
|
||||
## Production Deployment
|
||||
|
||||
### Using Docker
|
||||
|
||||
Build and run the production container:
|
||||
|
||||
```bash
|
||||
# Build the Docker image (using meet.sh)
|
||||
./meet.sh build-docker openvidu-meet-ce
|
||||
|
||||
# Build Docker image for demos (different BASE_HREF)
|
||||
./meet.sh build-docker openvidu-meet-ce --demos
|
||||
|
||||
# Run the container
|
||||
docker run \
|
||||
-e LIVEKIT_URL=<your-livekit-url> \
|
||||
-e LIVEKIT_API_KEY=<your-livekit-api-key> \
|
||||
@ -131,4 +236,166 @@ docker run \
|
||||
openvidu-meet-ce
|
||||
```
|
||||
|
||||
You can check all the available environment variables in the [environment file](backend/src/environment.ts).
|
||||
### Manual Production Start
|
||||
|
||||
```bash
|
||||
# Build all components
|
||||
./meet.sh build
|
||||
|
||||
# Start in production mode
|
||||
./meet.sh start --prod
|
||||
|
||||
# Or start in CI mode
|
||||
./meet.sh start --ci
|
||||
```
|
||||
|
||||
### Environment Variables
|
||||
|
||||
Configure your production environment using these key variables:
|
||||
|
||||
- `LIVEKIT_URL`: WebSocket URL for LiveKit server
|
||||
- `LIVEKIT_API_KEY`: LiveKit API key
|
||||
- `LIVEKIT_API_SECRET`: LiveKit API secret
|
||||
- `SERVER_PORT`: Backend server port (default: 6080)
|
||||
- `NODE_ENV`: Environment mode (`development`, `production`, `ci`)
|
||||
|
||||
For a complete list of environment variables, see [backend/src/environment.ts](backend/src/environment.ts).
|
||||
|
||||
## Project Structure
|
||||
|
||||
```
|
||||
openvidu-meet/
|
||||
├── meet.sh # Main build and development script
|
||||
├── pnpm-workspace.yaml # pnpm workspace configuration
|
||||
├── package.json # Root package with scripts
|
||||
│
|
||||
├── typings/ # Shared TypeScript definitions
|
||||
│ ├── src/
|
||||
│ │ ├── api-key.ts
|
||||
│ │ ├── auth-config.ts
|
||||
│ │ ├── participant.ts
|
||||
│ │ ├── event.model.ts
|
||||
│ │ └── ...
|
||||
│ └── package.json
|
||||
│
|
||||
├── frontend/ # Angular frontend application
|
||||
│ ├── src/ # Main application source
|
||||
│ ├── projects/
|
||||
│ │ └── shared-meet-components/ # Reusable Angular library
|
||||
│ └── webcomponent/ # Web component build
|
||||
│
|
||||
├── backend/ # Node.js/Express backend
|
||||
│ ├── src/
|
||||
│ │ ├── controllers/ # REST API controllers
|
||||
│ │ ├── services/ # Business logic
|
||||
│ │ ├── middleware/ # Express middleware
|
||||
│ │ └── environment.ts # Environment configuration
|
||||
│ ├── openapi/ # OpenAPI specifications
|
||||
│ └── public/ # Static files (includes built frontend)
|
||||
│
|
||||
├── testapp/ # Testing application
|
||||
│ ├── src/
|
||||
│ └── public/
|
||||
│
|
||||
├── docker/ # Docker build files
|
||||
│ └── create_image.sh
|
||||
│
|
||||
├── docs/ # Generated documentation
|
||||
├── scripts/ # Build and utility scripts
|
||||
└── openvidu-meet-pro/ # Professional Edition (separate license)
|
||||
```
|
||||
|
||||
## Using the meet.sh Script
|
||||
|
||||
The `meet.sh` script is the main entry point for all development and build tasks:
|
||||
|
||||
### Command Reference
|
||||
|
||||
```bash
|
||||
# Help
|
||||
./meet.sh help
|
||||
|
||||
# Installation
|
||||
./meet.sh install # Install all dependencies
|
||||
|
||||
# Building
|
||||
./meet.sh build # Build all components
|
||||
./meet.sh build-typings # Build shared types only
|
||||
./meet.sh build-webcomponent # Build webcomponent only
|
||||
./meet.sh build-testapp # Build test application
|
||||
|
||||
# Development
|
||||
./meet.sh dev # Start development mode with watchers
|
||||
|
||||
# Testing
|
||||
./meet.sh test-unit-backend # Run backend unit tests
|
||||
./meet.sh test-unit-webcomponent # Run webcomponent unit tests
|
||||
./meet.sh test-e2e-webcomponent # Run webcomponent E2E tests
|
||||
|
||||
# Running
|
||||
./meet.sh start --prod # Start in production mode
|
||||
./meet.sh start --ci # Start in CI mode
|
||||
./meet.sh start-testapp # Start test application
|
||||
|
||||
# Documentation
|
||||
./meet.sh build-webcomponent-doc [dir] # Generate webcomponent docs
|
||||
./meet.sh build-rest-api-doc [dir] # Generate REST API docs
|
||||
|
||||
# Docker
|
||||
./meet.sh build-docker <image-name> [--demos] # Build Docker image
|
||||
```
|
||||
|
||||
### Examples
|
||||
|
||||
```bash
|
||||
# Full development workflow
|
||||
./meet.sh install
|
||||
./meet.sh dev
|
||||
|
||||
# CI/CD optimized workflow
|
||||
./meet.sh install
|
||||
./meet.sh build-typings
|
||||
./meet.sh build-webcomponent --skip-install --skip-typings
|
||||
./meet.sh test-unit-webcomponent --skip-install
|
||||
|
||||
# Production build and deploy
|
||||
./meet.sh build
|
||||
./meet.sh start --prod
|
||||
|
||||
# Build Docker image
|
||||
./meet.sh build-docker openvidu-meet-ce
|
||||
|
||||
# Build Docker image for demos
|
||||
./meet.sh build-docker openvidu-meet-ce --demos
|
||||
```
|
||||
|
||||
## Technologies
|
||||
|
||||
- **Frontend**: Angular 20, Material Design, TypeScript
|
||||
- **Backend**: Node.js, Express, TypeScript
|
||||
- **WebRTC Infrastructure**: LiveKit
|
||||
- **Package Manager**: pnpm (workspaces)
|
||||
- **Build Tools**: Angular CLI, TypeScript Compiler, Rollup (webcomponent)
|
||||
- **Testing**: Jest (unit), Playwright (E2E), Mocha
|
||||
- **Documentation**: OpenAPI/Swagger, Custom generators
|
||||
|
||||
## Contributing
|
||||
|
||||
Contributions are welcome! Please ensure that:
|
||||
|
||||
1. All tests pass: `./meet.sh test-unit-backend && ./meet.sh test-unit-webcomponent`
|
||||
2. Code is properly formatted
|
||||
3. TypeScript types are correctly defined in `typings/`
|
||||
4. Documentation is updated as needed
|
||||
|
||||
## License
|
||||
|
||||
Licensed under the Apache License, Version 2.0. See [LICENSE](LICENSE) for details.
|
||||
|
||||
## Links
|
||||
|
||||
- [OpenVidu Website](https://openvidu.io/)
|
||||
- [OpenVidu Meet](https://openvidu.io/latest/meet/)
|
||||
---
|
||||
|
||||
For questions and support, visit our [community forum](https://openvidu.discourse.group/).
|
||||
|
||||
@ -1,12 +0,0 @@
|
||||
{
|
||||
"env": {
|
||||
"NODE_ENV": "development"
|
||||
},
|
||||
"watch": ["openapi/**/*.yaml", "src", "../typings/src"],
|
||||
"ext": "js,json,ts,yaml,yml",
|
||||
"ignore": ["node_modules", "dist", "src/typings", "public"],
|
||||
"exec": "node --import tsx ./src/server.ts",
|
||||
"events": {
|
||||
"restart": "npm run typings:sync && npm run doc:api && npm run doc:internal-api"
|
||||
}
|
||||
}
|
||||
13946
backend/package-lock.json
generated
13946
backend/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -1,115 +0,0 @@
|
||||
{
|
||||
"name": "openvidu-meet-backend",
|
||||
"version": "3.4.1",
|
||||
"description": "OpenVidu Meet Backend",
|
||||
"author": "OpenVidu",
|
||||
"license": "Apache-2.0",
|
||||
"homepage": "https://github.com/OpenVidu/openvidu-meet#readme",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/OpenVidu/openvidu-meet.git"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/OpenVidu/openvidu-meet/issues"
|
||||
},
|
||||
"keywords": [
|
||||
"openvidu",
|
||||
"webrtc",
|
||||
"openvidu-meet"
|
||||
],
|
||||
"main": "dist/index.js",
|
||||
"types": "dist/index.d.ts",
|
||||
"type": "module",
|
||||
"files": [
|
||||
"dist",
|
||||
"src",
|
||||
"openapi",
|
||||
"package.json"
|
||||
],
|
||||
"scripts": {
|
||||
"build:prod": "tsc",
|
||||
"postbuild:prod": "npm run doc:api && npm run doc:internal-api",
|
||||
"doc:api": "mkdir -p public/openapi && cd openapi && npx openapi-generate-html -i openvidu-meet-api.yaml --ui=stoplight --theme=light --title 'OpenVidu Meet REST API' --description 'OpenVidu Meet REST API' -o ../public/openapi/public.html",
|
||||
"doc:internal-api": "mkdir -p public/openapi && cd openapi && npx openapi-generate-html -i openvidu-meet-internal-api.yaml --ui=stoplight --theme=dark --title 'OpenVidu Meet Internal REST API' --description 'OpenVidu Meet Internal REST API' -o ../public/openapi/internal.html",
|
||||
"start:prod": "NODE_ENV=production node dist/src/server.js",
|
||||
"start:dev": "NODE_ENV=development nodemon",
|
||||
"start:ci": "NODE_ENV=ci node dist/src/server.js",
|
||||
"package:build": "npm run build:prod && npm pack",
|
||||
"lib:sync-pro": "npm run package:build && cp openvidu-meet-server-*.tgz ../../openvidu-meet-pro/backend",
|
||||
"typings:sync": "npm run sync-ce --prefix ../typings",
|
||||
"test:integration": "node --experimental-vm-modules node_modules/.bin/jest --runInBand --forceExit --testPathPattern \"tests/integration\" --ci --reporters=default --reporters=jest-junit",
|
||||
"test:integration-rooms": "node --experimental-vm-modules node_modules/.bin/jest --runInBand --forceExit --testPathPattern \"tests/integration/api/rooms\" --ci --reporters=default --reporters=jest-junit",
|
||||
"test:integration-recordings": "node --experimental-vm-modules node_modules/.bin/jest --maxWorkers=1 --maxConcurrency=1 --forceExit --testPathPattern \"tests/integration/api/recordings\" --ci --reporters=default --reporters=jest-junit",
|
||||
"test:integration-webhooks": "node --experimental-vm-modules node_modules/.bin/jest --runInBand --forceExit --testPathPattern \"tests/integration/webhooks\" --ci --reporters=default --reporters=jest-junit",
|
||||
"test:integration-security": "node --experimental-vm-modules node_modules/.bin/jest --runInBand --forceExit --testPathPattern \"tests/integration/api/security\" --ci --reporters=default --reporters=jest-junit",
|
||||
"test:integration-global-config": "node --experimental-vm-modules node_modules/.bin/jest --runInBand --forceExit --testPathPattern \"tests/integration/api/global-config\" --ci --reporters=default --reporters=jest-junit",
|
||||
"test:integration-participants": "node --experimental-vm-modules node_modules/.bin/jest --runInBand --forceExit --testPathPattern \"tests/integration/api/participants\" --ci --reporters=default --reporters=jest-junit",
|
||||
"test:integration-meetings": "node --experimental-vm-modules node_modules/.bin/jest --runInBand --forceExit --testPathPattern \"tests/integration/api/meetings\" --ci --reporters=default --reporters=jest-junit",
|
||||
"test:integration-users": "node --experimental-vm-modules node_modules/.bin/jest --runInBand --forceExit --testPathPattern \"tests/integration/api/users\" --ci --reporters=default --reporters=jest-junit",
|
||||
"test:unit": "node --experimental-vm-modules node_modules/.bin/jest --runInBand --forceExit --testPathPattern \"tests/unit\" --ci --reporters=default --reporters=jest-junit",
|
||||
"lint:fix": "eslint src --fix",
|
||||
"format:code": "prettier --ignore-path .gitignore --write '**/*.{ts,js,json,md}'"
|
||||
},
|
||||
"dependencies": {
|
||||
"@aws-sdk/client-s3": "3.846.0",
|
||||
"@azure/storage-blob": "12.27.0",
|
||||
"@google-cloud/storage": "7.17.1",
|
||||
"@sesamecare-oss/redlock": "1.4.0",
|
||||
"archiver": "7.0.1",
|
||||
"bcrypt": "5.1.1",
|
||||
"body-parser": "2.2.0",
|
||||
"chalk": "5.6.2",
|
||||
"cookie-parser": "1.4.7",
|
||||
"cors": "2.8.5",
|
||||
"cron": "4.3.3",
|
||||
"dotenv": "16.6.1",
|
||||
"express": "4.21.2",
|
||||
"express-openapi-validator": "5.5.7",
|
||||
"express-rate-limit": "7.5.1",
|
||||
"inversify": "6.2.2",
|
||||
"ioredis": "5.6.1",
|
||||
"jwt-decode": "4.0.0",
|
||||
"livekit-server-sdk": "2.13.1",
|
||||
"ms": "2.1.3",
|
||||
"uid": "2.0.2",
|
||||
"winston": "3.18.3",
|
||||
"yamljs": "0.3.0",
|
||||
"zod": "3.25.76"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/archiver": "6.0.3",
|
||||
"@types/bcrypt": "5.0.2",
|
||||
"@types/cookie-parser": "1.4.9",
|
||||
"@types/cors": "2.8.19",
|
||||
"@types/express": "4.17.23",
|
||||
"@types/jest": "29.5.14",
|
||||
"@types/ms": "2.1.0",
|
||||
"@types/node": "22.16.4",
|
||||
"@types/supertest": "6.0.3",
|
||||
"@types/swagger-ui-express": "4.1.8",
|
||||
"@types/unzipper": "0.10.11",
|
||||
"@types/validator": "13.15.2",
|
||||
"@types/yamljs": "0.2.34",
|
||||
"@typescript-eslint/eslint-plugin": "6.21.0",
|
||||
"@typescript-eslint/parser": "6.21.0",
|
||||
"cross-env": "7.0.3",
|
||||
"eslint": "8.57.1",
|
||||
"eslint-config-prettier": "9.1.0",
|
||||
"jest": "29.7.0",
|
||||
"jest-fetch-mock": "3.0.3",
|
||||
"jest-junit": "16.0.0",
|
||||
"nodemon": "3.1.10",
|
||||
"openapi-generate-html": "0.4.4",
|
||||
"prettier": "3.6.2",
|
||||
"supertest": "7.1.3",
|
||||
"ts-jest": "29.4.0",
|
||||
"ts-jest-resolver": "2.0.1",
|
||||
"tsx": "4.20.3",
|
||||
"typescript": "5.8.3",
|
||||
"unzipper": "0.12.3"
|
||||
},
|
||||
"jest-junit": {
|
||||
"outputDirectory": "test-results",
|
||||
"outputName": "junit.xml"
|
||||
}
|
||||
}
|
||||
@ -1,50 +0,0 @@
|
||||
# ====================================================
|
||||
# Stage 1: builder
|
||||
# ====================================================
|
||||
FROM node:22.19.0 AS builder
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
RUN mkdir -p typings frontend backend && chown -R node:node /app
|
||||
|
||||
USER node
|
||||
|
||||
COPY --chown=node:node frontend/package*.json ./frontend/
|
||||
COPY --chown=node:node backend/package*.json ./backend/
|
||||
COPY --chown=node:node typings/package*.json ./typings/
|
||||
COPY --chown=node:node . .
|
||||
|
||||
ARG BASE_HREF=/
|
||||
|
||||
# Prepare project
|
||||
RUN chmod +x prepare.sh && \
|
||||
sh ./prepare.sh --typings --frontend --webcomponent --backend
|
||||
|
||||
# Clean up
|
||||
RUN rm -rf frontend/node_modules backend/node_modules && \
|
||||
rm -rf typings
|
||||
|
||||
# ====================================================
|
||||
# Stage 2: production
|
||||
# ====================================================
|
||||
FROM node:22.19.0-alpine3.21 AS production
|
||||
|
||||
WORKDIR /opt/openvidu-meet
|
||||
|
||||
COPY backend/package*.json ./
|
||||
RUN npm ci --production
|
||||
|
||||
# Copy the frontend and backend from the builder
|
||||
COPY --from=builder /app/backend/dist ./dist
|
||||
COPY --from=builder /app/backend/public ./dist/public
|
||||
|
||||
COPY docker/entrypoint.sh /usr/local/bin/entrypoint.sh
|
||||
|
||||
RUN chmod +x /usr/local/bin/entrypoint.sh && \
|
||||
chown -R node:node /opt/openvidu-meet
|
||||
|
||||
ENV NODE_ENV=production
|
||||
|
||||
EXPOSE $SERVER_PORT
|
||||
|
||||
CMD ["/usr/local/bin/entrypoint.sh"]
|
||||
@ -1,11 +0,0 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
IMAGE=${1:-?echo "Error: You need to specify an image name as first argument"?}
|
||||
if [[ -n $IMAGE ]]; then
|
||||
cd ..
|
||||
export BUILDKIT_PROGRESS=plain && \
|
||||
docker build --pull --no-cache --rm=true -f docker/Dockerfile -t "$IMAGE" --build-arg BASE_HREF=/ .
|
||||
echo "Docker image '$IMAGE' built successfully."
|
||||
else
|
||||
echo "Error: You need to specify an image name as first argument"
|
||||
fi
|
||||
@ -1,9 +0,0 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
IMAGE="${1:-?echo "Error: You need to specify an image name as first argument"?}"
|
||||
if [[ -n $IMAGE ]]; then
|
||||
cd ..
|
||||
export BUILDKIT_PROGRESS=plain && docker build --pull --no-cache --rm=true -f docker/Dockerfile -t "$IMAGE"-demos --build-arg BASE_HREF=/openvidu-meet/ .
|
||||
else
|
||||
echo "Error: You need to specify the image name as first argument"
|
||||
fi
|
||||
19291
frontend/package-lock.json
generated
19291
frontend/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -1,85 +0,0 @@
|
||||
{
|
||||
"name": "openvidu-meet-frontend",
|
||||
"version": "3.4.1",
|
||||
"scripts": {
|
||||
"start:dev": "npx ng serve --configuration development --port=5080 --host=0.0.0.0",
|
||||
"build:dev": "npx ng build --configuration development --watch",
|
||||
"build": "func() { ./node_modules/@angular/cli/bin/ng.js build --configuration production --base-href=\"${1:-/}\"; }; func",
|
||||
"typings:sync": "npm run sync-ce --prefix ../typings",
|
||||
"sync:backend": "npx ng build --configuration production --output-path ../backend/dist/public/",
|
||||
"e2e:run-all": "npx mocha --recursive --timeout 30000 ./tests/e2e/**/*.test.ts",
|
||||
"e2e:run-routes": "npx mocha --recursive --timeout 30000 ./tests/e2e/routes.test.ts",
|
||||
"e2e:run-home": "npx mocha ./tests/e2e/home.test.ts",
|
||||
"e2e:run-recordings": "npx mocha --recursive --timeout 30000 ./tests/e2e/recording.test.ts",
|
||||
"e2e:run-auth": "npx mocha --recursive --timeout 30000 ./tests/e2e/auth.test.ts",
|
||||
"lib:serve": "npx ng build shared-meet-components --watch",
|
||||
"lib:build": "ng build shared-meet-components --configuration production",
|
||||
"lib:pack": "cd dist/shared-meet-components && npm pack",
|
||||
"lib:sync-pro": "npm run lib:build && npm run lib:pack && cp dist/shared-meet-components/shared-meet-components-**.tgz ../../openvidu-meet-pro/frontend",
|
||||
"test:unit": "ng test openvidu-meet --watch=false --code-coverage",
|
||||
"webcomponent:build": "npm run build --prefix webcomponent",
|
||||
"webcomponent:unit-test": "node --experimental-vm-modules node_modules/.bin/jest --config jest.config.mjs",
|
||||
"lint:fix": "eslint src --fix",
|
||||
"format:code": "prettier --ignore-path ../gitignore . --write"
|
||||
},
|
||||
"dependencies": {
|
||||
"@angular/animations": "20.3.3",
|
||||
"@angular/cdk": "20.2.7",
|
||||
"@angular/common": "20.3.3",
|
||||
"@angular/compiler": "20.3.3",
|
||||
"@angular/core": "20.3.3",
|
||||
"@angular/forms": "20.3.3",
|
||||
"@angular/material": "20.2.7",
|
||||
"@angular/platform-browser": "20.3.3",
|
||||
"@angular/platform-browser-dynamic": "20.3.3",
|
||||
"@angular/router": "20.3.3",
|
||||
"core-js": "3.45.1",
|
||||
"jwt-decode": "4.0.0",
|
||||
"openvidu-components-angular": "file:openvidu-components-angular-3.4.0.tgz",
|
||||
"rxjs": "7.8.2",
|
||||
"tslib": "2.8.1",
|
||||
"unique-names-generator": "4.7.1",
|
||||
"zone.js": "0.15.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@angular-builders/custom-webpack": "20.0.0",
|
||||
"@angular-devkit/build-angular": "20.3.4",
|
||||
"@angular-eslint/builder": "20.3.0",
|
||||
"@angular-eslint/eslint-plugin": "20.3.0",
|
||||
"@angular-eslint/eslint-plugin-template": "20.3.0",
|
||||
"@angular-eslint/schematics": "20.3.0",
|
||||
"@angular-eslint/template-parser": "20.3.0",
|
||||
"@angular/cli": "20.3.4",
|
||||
"@angular/compiler-cli": "20.3.3",
|
||||
"@types/chai": "4.3.20",
|
||||
"@types/fluent-ffmpeg": "2.1.27",
|
||||
"@types/jasmine": "5.1.9",
|
||||
"@types/mocha": "9.1.1",
|
||||
"@types/node": "22.18.8",
|
||||
"@types/pixelmatch": "5.2.6",
|
||||
"@types/pngjs": "6.0.5",
|
||||
"@types/selenium-webdriver": "4.35.1",
|
||||
"@typescript-eslint/eslint-plugin": "7.18.0",
|
||||
"@typescript-eslint/parser": "7.18.0",
|
||||
"chai": "4.5.0",
|
||||
"chromedriver": "141.0.0",
|
||||
"cross-env": "7.0.3",
|
||||
"eslint": "8.57.1",
|
||||
"eslint-config-prettier": "9.1.0",
|
||||
"fluent-ffmpeg": "2.1.3",
|
||||
"jasmine-core": "5.6.0",
|
||||
"jasmine-spec-reporter": "7.0.0",
|
||||
"karma": "6.4.4",
|
||||
"karma-chrome-launcher": "3.2.0",
|
||||
"karma-coverage": "2.2.1",
|
||||
"karma-jasmine": "5.1.0",
|
||||
"karma-jasmine-html-reporter": "2.1.0",
|
||||
"mocha": "10.7.3",
|
||||
"ng-packagr": "20.3.0",
|
||||
"prettier": "3.3.3",
|
||||
"selenium-webdriver": "4.25.0",
|
||||
"ts-node": "10.9.2",
|
||||
"tslib": "2.6.3",
|
||||
"typescript": "5.8.3"
|
||||
}
|
||||
}
|
||||
@ -1,19 +0,0 @@
|
||||
{
|
||||
"name": "shared-meet-components",
|
||||
"version": "0.0.1",
|
||||
"peerDependencies": {
|
||||
"@angular/animations": "^18.0.0",
|
||||
"@angular/cdk": "^18.0.0",
|
||||
"@angular/common": "^18.2.0",
|
||||
"@angular/core": "^18.2.0",
|
||||
"@angular/forms": "^18.0.0",
|
||||
"@angular/material": " ^18.0.0",
|
||||
"jwt-decode": "^4.0.0",
|
||||
"openvidu-components-angular": "^3.0.0",
|
||||
"rxjs": "7.8.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"tslib": "^2.3.0"
|
||||
},
|
||||
"sideEffects": false
|
||||
}
|
||||
10027
frontend/webcomponent/package-lock.json
generated
10027
frontend/webcomponent/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -7,8 +7,8 @@ This is the backend of OpenVidu Meet. It is a Node.js application that uses [Exp
|
||||
For running the backend you need to have installed [Node.js](https://nodejs.org/). Then, you can run the following commands:
|
||||
|
||||
```bash
|
||||
npm install
|
||||
npm run start:dev
|
||||
pnpm install
|
||||
pnpm run start:dev
|
||||
```
|
||||
|
||||
This will start the backend in development mode. The server will listen on port 6080.
|
||||
@ -19,8 +19,8 @@ You can change the port and other default values in the file `src/config.ts`.
|
||||
For building the backend you can run the following command:
|
||||
|
||||
```bash
|
||||
npm install
|
||||
npm run build:prod
|
||||
pnpm install
|
||||
pnpm run build:prod
|
||||
```
|
||||
|
||||
## Storage Structure
|
||||
@ -11,14 +11,14 @@ const jestConfig = {
|
||||
testMatch: ['**/?(*.)+(spec|test).[tj]s?(x)'],
|
||||
moduleFileExtensions: ['js', 'ts', 'json', 'node'],
|
||||
testEnvironment: 'node',
|
||||
moduleNameMapper: {
|
||||
'^@typings-ce$': '<rootDir>/src/typings/ce/index.ts'
|
||||
},
|
||||
globals: {
|
||||
'ts-jest': {
|
||||
tsconfig: 'tsconfig.json'
|
||||
}
|
||||
}
|
||||
},
|
||||
moduleNameMapper: {
|
||||
'^@openvidu-meet/typings$': '<rootDir>/../typings/src/index.ts'
|
||||
},
|
||||
// transform: {
|
||||
// '^.+\\.tsx?$': ['ts-jest', {
|
||||
// // Opcionalmente, especifica el archivo tsconfig si es necesario
|
||||
6
meet-ce/backend/nodemon.docs.json
Normal file
6
meet-ce/backend/nodemon.docs.json
Normal file
@ -0,0 +1,6 @@
|
||||
{
|
||||
"watch": ["openapi/**/*.yaml", "openapi/**/*.yml"],
|
||||
"ext": "yaml,yml",
|
||||
"ignore": [],
|
||||
"exec": "pnpm --filter openvidu-meet-backend run doc:api && pnpm --filter openvidu-meet-backend run doc:internal-api && echo '✅ OpenVidu Meet REST API docs updated successfully!'"
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user