diff --git a/.github/dependabot.yml b/.github/dependabot.yml deleted file mode 100644 index 09e46023eb..0000000000 --- a/.github/dependabot.yml +++ /dev/null @@ -1,71 +0,0 @@ -# To get started with Dependabot version updates, you'll need to specify which -# package ecosystems to update and where the package manifests are located. -# Please see the documentation for all configuration options: -# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates - -version: 2 -updates: - # Maintain dependencies for npm - - package-ecosystem: "npm" - directory: "/" - open-pull-requests-limit: 20 - cooldown: - default-days: 7 - schedule: - interval: "weekly" - day: "monday" - time: "06:00" - timezone: "Europe/Berlin" - groups: - tiptap: - patterns: - - "@tiptap*" - primevue: - patterns: - - "primevue*" - - "@primevue*" - - # Maintain dependencies for Composer - - package-ecosystem: "composer" - directory: "/" - open-pull-requests-limit: 20 - cooldown: - default-days: 7 - schedule: - interval: "weekly" - day: "monday" - time: "06:00" - timezone: "Europe/Berlin" - groups: - laravel: - patterns: - - "laravel/*" - phpunit: - patterns: - - "brianium/paratest" - - "phpunit/phpunit" - - # Github Actions updates - - package-ecosystem: "github-actions" - directory: "/" - cooldown: - default-days: 7 - schedule: - interval: "weekly" - day: "monday" - time: "06:00" - timezone: "Europe/Berlin" - # Docs dependencies for npm - - package-ecosystem: "npm" - directory: "/docs" - cooldown: - default-days: 7 - schedule: - interval: "weekly" - day: "monday" - time: "06:00" - timezone: "Europe/Berlin" - groups: - docs: - patterns: ["*"] - update-types: ["minor", "patch"] diff --git a/.github/workflows/ci-docker.yml b/.github/workflows/ci-docker.yml deleted file mode 100644 index 8448cd3fa7..0000000000 --- a/.github/workflows/ci-docker.yml +++ /dev/null @@ -1,72 +0,0 @@ -name: CI Docker build - -on: - workflow_dispatch: - schedule: - - cron: "0 0 * * *" # Nightly - release: - types: [published] - push: - branches: - - develop - - "[0-9].x" - paths-ignore: - - "docs/**" - -permissions: - contents: read - -jobs: - build-and-push-image: - runs-on: ubuntu-latest - - steps: - - name: Checkout repository - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - persist-credentials: false - - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@4d04d5d9486b7bd6fa91e7baf45bbb4f8b9deedd # v4.0.0 - - - name: Login to Docker Hub - uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4.1.0 - with: - username: ${{ secrets.DOCKER_HUB_USERNAME }} - password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} - - - name: Extract metadata (tags, labels) for Docker - id: meta - uses: docker/metadata-action@030e881283bb7a6894de51c315a6bfe6a94e05cf # v6.0.0 - with: - images: pilos/pilos - flavor: | - latest=auto - prefix= - suffix= - tags: | - type=semver,pattern={{version}} - type=semver,pattern={{major}}.{{minor}} - type=semver,pattern={{major}} - type=ref,event=branch,prefix=dev- - - - name: Set version to tag name - if: ${{ github.event_name == 'release' }} - run: echo "${GITHUB_REF_NAME}" > version - - - name: Set version to commit short hash - if: ${{ github.event_name != 'release' }} - run: echo "${GITHUB_SHA}" | cut -c1-7 > version - - - name: Build and push Docker image - uses: docker/build-push-action@bcafcacb16a39f128d818304e6c9c0c18556b85f # v7.1.0 - with: - file: docker/app/Dockerfile - context: . - push: true - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} - cache-from: type=gha - cache-to: type=gha,mode=max - no-cache: ${{ github.event_name == 'schedule' }} - pull: ${{ github.event_name == 'schedule' }} diff --git a/.github/workflows/ci-docs.yml b/.github/workflows/ci-docs.yml deleted file mode 100644 index 17540106de..0000000000 --- a/.github/workflows/ci-docs.yml +++ /dev/null @@ -1,35 +0,0 @@ -name: Test building docs - -on: - pull_request: - paths: - - "docs/**" - -permissions: - contents: read - -jobs: - build: - name: Build docs - runs-on: ubuntu-latest - defaults: - run: - working-directory: ./docs - steps: - # Setup - - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - persist-credentials: false - - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 - with: - node-version: 24 - cache: npm - cache-dependency-path: ./docs/package-lock.json - - name: Install dependencies - run: npm ci - - # Build static docs - - name: Build all versions - run: ./build.sh - - name: Build website - run: npm run docusaurus build diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml deleted file mode 100644 index 9632807090..0000000000 --- a/.github/workflows/ci.yml +++ /dev/null @@ -1,477 +0,0 @@ -name: CI - -on: - push: - branches: - - develop - - "[0-9].x" - paths-ignore: - - "docs/**" - pull_request: - paths-ignore: - - "docs/**" - -env: - PHP_VERSION: 8.5 - CYPRESS_PROJECT_ID: w8t3fx - -permissions: - contents: read - -jobs: - backend: - name: Backend - runs-on: ubuntu-latest - - services: - redis: - image: redis:8-alpine - options: >- - --health-cmd "redis-cli ping" - --health-interval 10s - --health-timeout 5s - --health-retries 5 - ports: - - 6379 - postgres: - image: postgres:18-alpine - env: - POSTGRES_USER: user - POSTGRES_PASSWORD: password - POSTGRES_DB: test - options: >- - --health-cmd pg_isready - --health-interval 10s - --health-timeout 5s - --health-retries 5 - ports: - - 5432 - - mariadb: - image: mariadb:11 - ports: - - 3306 - env: - MARIADB_USER: user - MARIADB_PASSWORD: password - MARIADB_DATABASE: test - MARIADB_ROOT_PASSWORD: password - options: --health-cmd="healthcheck.sh --connect --innodb_initialized" --health-interval=5s --health-timeout=2s --health-retries=3 - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - fetch-depth: 2 - persist-credentials: false - - name: Verify MariaDB connection - env: - PORT: ${{ job.services.mariadb.ports[3306] }} - run: | - while ! mysqladmin ping -h"127.0.0.1" -P"$PORT" --silent; do - sleep 1 - done - - name: Verify Postgres connection - env: - PORT: ${{ job.services.postgres.ports[5432] }} - run: | - while ! pg_isready -h"127.0.0.1" -p"$PORT" > /dev/null 2> /dev/null; do - sleep 1 - done - - name: Install packages - run: | - sudo apt-get update - sudo apt-get install pv mariadb-client - - name: Setup PHP, with composer and extensions - uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # 2.37.0 - with: - php-version: ${{ env.PHP_VERSION }} - extensions: bcmath, ctype, fileinfo, json, mbstring, dom, ldap, pdo, tokenizer, xml, mysql, sqlite, imagick, exif, intl - coverage: pcov - - name: Copy .env - run: php -r "copy('.env.ci', '.env');" - - name: Get Composer Cache Directory - id: composer-cache - run: | - echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT - - uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5 - with: - path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} - restore-keys: | - ${{ runner.os }}-composer- - - name: Install php dependencies - run: | - composer self-update - composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist - - name: Generate key - run: php artisan key:generate - - name: Directory Permissions - run: chmod -R 777 storage bootstrap/cache - - name: Migrate Database - env: - DB_HOST: 127.0.0.1 - DB_PORT: ${{ job.services.mariadb.ports[3306] }} - DB_DATABASE: test - DB_USERNAME: root - DB_PASSWORD: password - run: php artisan migrate --no-interaction -vvv --force - - name: Execute code style check via Laravel Pint - run: vendor/bin/pint --test -v - - name: Execute tests (Unit and Feature tests) via PHPUnit - if: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.fork }} - env: - DB_HOST: 127.0.0.1 - DB_PORT: ${{ job.services.mariadb.ports[3306] }} - DB_DATABASE: test - DB_USERNAME: root - DB_PASSWORD: password - REDIS_HOST: 127.0.0.1 - REDIS_PORT: ${{ job.services.redis.ports[6379] }} - LOG_CHANNEL: stack - run: php artisan test --parallel --testsuite=Unit,Feature --coverage-clover=coverage.xml - - name: Execute tests (Unit, Feature and Integration tests) via PHPUnit - if: ${{ github.event_name != 'pull_request' || !github.event.pull_request.head.repo.fork }} - env: - DB_HOST: 127.0.0.1 - DB_PORT: ${{ job.services.mariadb.ports[3306] }} - DB_DATABASE: test - DB_USERNAME: root - DB_PASSWORD: password - REDIS_HOST: 127.0.0.1 - REDIS_PORT: ${{ job.services.redis.ports[6379] }} - LOG_CHANNEL: stack - BBB_TEST_SERVER_HOST: ${{ secrets.BBB_TEST_SERVER_HOST }} - BBB_TEST_SERVER_SECRET: ${{ secrets.BBB_TEST_SERVER_SECRET }} - run: php artisan test --parallel --coverage-clover=coverage.xml - - name: Execute tests (Unit and Feature tests) via PHPUnit using Postgres - env: - DB_CONNECTION: pgsql - DB_HOST: 127.0.0.1 - DB_PORT: ${{ job.services.postgres.ports[5432] }} - DB_DATABASE: test - DB_USERNAME: user - DB_PASSWORD: password - REDIS_HOST: 127.0.0.1 - REDIS_PORT: ${{ job.services.redis.ports[6379] }} - LOG_CHANNEL: stack - run: php artisan test --parallel --testsuite=Unit,Feature - - name: Upload coverage - uses: codecov/codecov-action@57e3a136b779b570ffcdbf80b3bdc90e7fab3de2 # v6.0.0 - with: - fail_ci_if_error: true - - name: Upload laravel logs - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 - if: failure() - with: - name: laravel-backend-tests.log - path: storage/logs/laravel.log - archive: false - frontend-code-style-check: - name: Frontend Code Style Check - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - persist-credentials: false - - name: Copy .env - run: php -r "copy('.env.example', '.env');" - - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 - with: - node-version: 24 - cache: "npm" - cache-dependency-path: ./package-lock.json - - name: Install dependencies - run: npm ci - - name: Check code formatting - run: npm run prettier - - name: Linting - run: npm run lint - docker-build: - name: Docker Build - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - persist-credentials: false - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@4d04d5d9486b7bd6fa91e7baf45bbb4f8b9deedd # v4.0.0 - - - name: Build and export - uses: docker/build-push-action@bcafcacb16a39f128d818304e6c9c0c18556b85f # v7.1.0 - with: - file: docker/app/Dockerfile - context: . - load: true - tags: pilos:latest - cache-from: type=gha - cache-to: type=gha,mode=max - outputs: type=docker,dest=/tmp/pilos-image.tar - build-args: | - VITE_COVERAGE=true - - name: Upload artifact - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 - with: - name: pilos-image.tar - path: /tmp/pilos-image.tar - archive: false - generate-frontend-matrix: - name: Generate Frontend Matrix - runs-on: ubuntu-latest - outputs: - record: ${{ steps.generate-matrix.outputs.record }} - tag: ${{ steps.generate-matrix.outputs.tag }} - matrix: ${{ steps.generate-matrix.outputs.matrix }} - frontend_group: ${{ steps.generate-matrix.outputs.frontend_group }} - visual_group: ${{ steps.generate-matrix.outputs.visual_group }} - system_group: ${{ steps.generate-matrix.outputs.system_group }} - steps: - - name: Generate matrix - id: generate-matrix - run: | - if [ ${{ (github.actor == 'dependabot[bot]' || github.event_name == 'push') && runner.debug != '1' }} = true ]; then - record=false - tag='' - frontend_group='' - visual_group='' - system_group='' - matrix='{ "containers": [1] }' - else - record=true - tag=${{ github.event_name }} - frontend_group="Frontend tests" - visual_group="Visual tests" - system_group="System tests" - matrix='{ "containers": [1,2,3,4,5] }' - fi - echo "record=$record" >> "$GITHUB_OUTPUT" - echo "tag=$tag" >> "$GITHUB_OUTPUT" - echo "frontend_group=$frontend_group" >> "$GITHUB_OUTPUT" - echo "visual_group=$visual_group" >> "$GITHUB_OUTPUT" - echo "system_group=$system_group" >> "$GITHUB_OUTPUT" - echo "matrix=$matrix" >> "$GITHUB_OUTPUT" - frontend-tests: - name: Frontend Tests - runs-on: ubuntu-latest - needs: - - docker-build - - generate-frontend-matrix - strategy: - # don't fail the entire matrix on failure - fail-fast: false - matrix: ${{ fromJson(needs.generate-frontend-matrix.outputs.matrix) }} - - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - persist-credentials: false - - name: Setup Node.js - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 - with: - node-version: "24" - - name: Download artifact - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 - with: - name: pilos-image.tar - path: /tmp - - name: Load image - run: | - docker load --input /tmp/pilos-image.tar - - - name: Copy .env - run: docker run --rm pilos:latest cat ./.env.ci > .env - - - name: Generate key - run: | - docker run --rm \ - --mount type=bind,source=${{ github.workspace }}/.env,target=/var/www/html/.env \ - --entrypoint /bin/bash \ - pilos:latest \ - -c "chown www-data:www-data .env && pilos-cli key:generate" - - - name: Adjust .env - run: | - sed -i 's/CONTAINER_IMAGE=.*/CONTAINER_IMAGE=pilos:latest/g' .env - sed -i 's|APP_URL=.*|APP_URL=http://localhost:9080|g' .env - sed -i 's|BBB_TEST_SERVER_HOST=.*|BBB_TEST_SERVER_HOST=${{ secrets.BBB_TEST_SERVER_HOST }}|g' .env - sed -i 's|BBB_TEST_SERVER_SECRET=.*|BBB_TEST_SERVER_SECRET=${{ secrets.BBB_TEST_SERVER_SECRET }}|g' .env - - - name: Start app - run: docker compose -f compose.test.yml -f compose.test.ci.yml up -d - - name: Cypress run frontend tests - uses: cypress-io/github-action@dace029018fcdf86e0df89a31bc3cfa5b32570d8 # v7.3.0 - with: - wait-on: "http://localhost:9080" # Waits for above - group: ${{ needs.generate-frontend-matrix.outputs.frontend_group }} - parallel: ${{ needs.generate-frontend-matrix.outputs.record }} - record: ${{ needs.generate-frontend-matrix.outputs.record }} - tag: ${{ needs.generate-frontend-matrix.outputs.tag }} - env: - CYPRESS_PROJECT_ID: ${{ env.CYPRESS_PROJECT_ID }} - CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }} - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - COMMIT_INFO_MESSAGE: ${{ github.event.pull_request.title }} - COMMIT_INFO_SHA: ${{ github.event.pull_request.head.sha }} - APP_URL: "http://localhost:9080" - TZ: "America/New_York" - ELECTRON_EXTRA_LAUNCH_ARGS: "--lang=en --force-prefers-reduced-motion" - - name: Upload screenshots - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 - if: always() - with: - name: cypress-frontend-screenshots - path: tests/Frontend/screenshots - - name: Upload coverage - uses: codecov/codecov-action@57e3a136b779b570ffcdbf80b3bdc90e7fab3de2 # v6.0.0 - with: - fail_ci_if_error: true - directory: coverage - visual-tests: - name: Visual Tests - runs-on: ubuntu-latest - needs: - - docker-build - - generate-frontend-matrix - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - persist-credentials: false - - name: Setup Node.js - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 - with: - node-version: "24" - - name: Fetch develop branch - if: github.ref != 'refs/heads/develop' - run: git fetch origin develop:develop - - name: Download artifact - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 - with: - name: pilos-image.tar - path: /tmp - - name: Load image - run: | - docker load --input /tmp/pilos-image.tar - - name: Copy .env - run: docker run --rm pilos:latest cat ./.env.ci > .env - - name: Generate key - run: | - docker run --rm \ - --mount type=bind,source=${{ github.workspace }}/.env,target=/var/www/html/.env \ - --entrypoint /bin/bash \ - pilos:latest \ - -c "chown www-data:www-data .env && pilos-cli key:generate" - - - name: Adjust .env - run: | - sed -i 's/CONTAINER_IMAGE=.*/CONTAINER_IMAGE=pilos:latest/g' .env - sed -i 's|APP_URL=.*|APP_URL=http://localhost:9080|g' .env - sed -i 's|BBB_TEST_SERVER_HOST=.*|BBB_TEST_SERVER_HOST=${{ secrets.BBB_TEST_SERVER_HOST }}|g' .env - sed -i 's|BBB_TEST_SERVER_SECRET=.*|BBB_TEST_SERVER_SECRET=${{ secrets.BBB_TEST_SERVER_SECRET }}|g' .env - - - name: Start app - run: docker compose -f compose.test.yml -f compose.test.ci.yml up -d - - - name: Run cypress - uses: cypress-io/github-action@dace029018fcdf86e0df89a31bc3cfa5b32570d8 # v7.3.0 - with: - command-prefix: npx happo -- npx - group: ${{ needs.generate-frontend-matrix.outputs.visual_group }} - record: ${{ needs.generate-frontend-matrix.outputs.record }} - tag: ${{ needs.generate-frontend-matrix.outputs.tag }} - project: ./tests/Visual - env: - NODE_OPTIONS: "--experimental-require-module" - HAPPO_API_KEY: ${{ secrets.HAPPO_API_KEY }} - HAPPO_API_SECRET: ${{ secrets.HAPPO_API_SECRET }} - HAPPO_DELETE_OLD_COMMENTS: true - HAPPO_CONFIG_FILE: "./tests/Visual/happo.config.js" - BASE_BRANCH: origin/develop - CYPRESS_PROJECT_ID: ${{ env.CYPRESS_PROJECT_ID }} - CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }} - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - COMMIT_INFO_MESSAGE: ${{ github.event.pull_request.title }} - COMMIT_INFO_SHA: ${{ github.event.pull_request.head.sha }} - APP_URL: "http://localhost:9080" - TZ: "America/New_York" - ELECTRON_EXTRA_LAUNCH_ARGS: "--lang=en --force-prefers-reduced-motion" - system-tests: - name: System Tests - runs-on: ubuntu-latest - needs: - - docker-build - - generate-frontend-matrix - if: ${{ github.event_name != 'pull_request' || !github.event.pull_request.head.repo.fork }} - - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - persist-credentials: false - - name: Setup Node.js - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 - with: - node-version: "24" - - name: Download artifact - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 - with: - name: pilos-image.tar - path: /tmp - - name: Load image - run: | - docker load --input /tmp/pilos-image.tar - docker image ls -a - - - name: Copy .env - run: docker run --rm pilos:latest cat ./.env.ci > .env - - - name: Generate key - run: | - docker run --rm \ - --mount type=bind,source=${{ github.workspace }}/.env,target=/var/www/html/.env \ - --entrypoint /bin/bash \ - pilos:latest \ - -c "chown www-data:www-data .env && pilos-cli key:generate" - - - name: Adjust .env - run: | - sed -i 's/CONTAINER_IMAGE=.*/CONTAINER_IMAGE=pilos:latest/g' .env - sed -i 's|APP_URL=.*|APP_URL=http://localhost:9080|g' .env - sed -i 's|BBB_TEST_SERVER_HOST=.*|BBB_TEST_SERVER_HOST=${{ secrets.BBB_TEST_SERVER_HOST }}|g' .env - sed -i 's|BBB_TEST_SERVER_SECRET=.*|BBB_TEST_SERVER_SECRET=${{ secrets.BBB_TEST_SERVER_SECRET }}|g' .env - - - name: Start app - run: docker compose -f compose.test.yml -f compose.test.ci.yml up -d - - - name: Cypress run system tests - uses: cypress-io/github-action@dace029018fcdf86e0df89a31bc3cfa5b32570d8 # v7.3.0 - with: - wait-on: "http://localhost:9080" # Waits for above - group: ${{ needs.generate-frontend-matrix.outputs.system_group }} - record: ${{ needs.generate-frontend-matrix.outputs.record }} - tag: ${{ needs.generate-frontend-matrix.outputs.tag }} - project: ./tests/System - env: - CYPRESS_PROJECT_ID: ${{ env.CYPRESS_PROJECT_ID }} - CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }} - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - COMMIT_INFO_MESSAGE: ${{ github.event.pull_request.title }} - COMMIT_INFO_SHA: ${{ github.event.pull_request.head.sha }} - APP_URL: "http://localhost:9080" - TZ: "America/New_York" - ELECTRON_EXTRA_LAUNCH_ARGS: "--lang=en --force-prefers-reduced-motion" - - name: Upload screenshots - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 - if: always() - with: - name: cypress-system-screenshots - path: tests/System/screenshots - - name: Upload laravel logs - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 - if: failure() - with: - name: laravel-system-tests.log - path: storage/logs/laravel.log - archive: false diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml deleted file mode 100644 index 2d404fea25..0000000000 --- a/.github/workflows/deploy-docs.yml +++ /dev/null @@ -1,65 +0,0 @@ -name: Build and Deploy Docs - -on: - workflow_dispatch: - push: - branches: - - "develop" - paths: - - "docs/**" - -permissions: - contents: read - -# Do not build the docs concurrently -concurrency: - group: docs - cancel-in-progress: true - -jobs: - build: - name: Build docs - runs-on: ubuntu-latest - defaults: - run: - working-directory: ./docs - steps: - # Setup - - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - persist-credentials: false - - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 - with: - node-version: 24 - cache: npm - cache-dependency-path: ./docs/package-lock.json - - name: Install dependencies - run: npm ci - - # Build static docs - - name: Build all versions - run: ./build.sh - - name: Build website - run: npm run docusaurus build - - name: upload build artifact - uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0 - with: - path: ./docs/build - - deploy: - name: Deploy docs to gh-pages - needs: build - - permissions: - pages: write - id-token: write - - environment: - name: Documentation - url: ${{ steps.deployment.outputs.page_url }} - - runs-on: ubuntu-latest - steps: - - name: deploy to GitHub Pages - id: deployment - uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5.0.0 diff --git a/.github/workflows/publiccode-yml-validation.yml b/.github/workflows/publiccode-yml-validation.yml deleted file mode 100644 index cd3d85d21e..0000000000 --- a/.github/workflows/publiccode-yml-validation.yml +++ /dev/null @@ -1,17 +0,0 @@ -name: publiccode.yml validation - -on: [pull_request, push] - -permissions: - contents: read - -jobs: - publiccode_yml_validation: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - persist-credentials: false - - uses: italia/publiccode-parser-action@21086c73ec0563e14c6748787efa1b34b025ad8c # v1.5.1 - with: - publiccode: "publiccode.yml" diff --git a/.github/workflows/pull-locales.yml b/.github/workflows/pull-locales.yml deleted file mode 100644 index 99b438724d..0000000000 --- a/.github/workflows/pull-locales.yml +++ /dev/null @@ -1,159 +0,0 @@ -name: Pull locales from POEditor - -on: - workflow_dispatch: - inputs: - poeditor_project_id: - required: true - description: "POEditor Project ID" - type: number - schedule: - - cron: "0 * * * *" - -env: - PHP_VERSION: 8.5 - -permissions: - contents: read - -concurrency: - group: pull-locales - cancel-in-progress: true - -jobs: - pull-locales: - name: Pull locales from POEditor - runs-on: ubuntu-latest - permissions: - contents: read - outputs: - has_changes: ${{ steps.locale-changes.outputs.has_changes }} - - services: - mariadb: - image: mariadb:11 - ports: - - 3306 - env: - MARIADB_USER: user - MARIADB_PASSWORD: password - MARIADB_DATABASE: test - MARIADB_ROOT_PASSWORD: password - options: --health-cmd="healthcheck.sh --connect --innodb_initialized" --health-interval=5s --health-timeout=2s --health-retries=3 - - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - fetch-depth: 2 - persist-credentials: false - - name: Verify MariaDB connection - env: - PORT: ${{ job.services.mariadb.ports[3306] }} - run: | - while ! mysqladmin ping -h"127.0.0.1" -P"$PORT" --silent; do - sleep 1 - done - - name: Setup PHP, with composer and extensions - uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # 2.37.0 - with: - php-version: ${{ env.PHP_VERSION }} - extensions: bcmath, ctype, fileinfo, json, mbstring, dom, ldap, pdo, tokenizer, xml, mysql, sqlite - coverage: pcov - - name: Copy .env - run: php -r "copy('.env.ci', '.env');" - - name: Get Composer Cache Directory - id: composer-cache - run: | - echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT - - uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5 - with: - path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} - restore-keys: | - ${{ runner.os }}-composer- - - name: Install php dependencies - run: | - composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist - - name: Generate key - run: php artisan key:generate - - name: Directory Permissions - run: chmod -R 777 storage bootstrap/cache - - name: Migrate Database - env: - DB_HOST: 127.0.0.1 - DB_PORT: ${{ job.services.mariadb.ports[3306] }} - DB_DATABASE: test - DB_USERNAME: root - DB_PASSWORD: password - run: php artisan migrate --no-interaction -vvv --force - - - name: Execute command to pull locales from POEditor - env: - DB_HOST: 127.0.0.1 - DB_PORT: ${{ job.services.mariadb.ports[3306] }} - DB_DATABASE: test - DB_USERNAME: root - DB_PASSWORD: password - POEDITOR_TOKEN: ${{ secrets.POEDITOR_TOKEN }} - POEDITOR_PROJECT: ${{ github.event.inputs.poeditor_project_id || secrets.POEDITOR_PROJECT}} - run: php artisan locales:import - - - name: Detect locale changes - id: locale-changes - run: | - git add -A lang - if git diff --cached --quiet; then - echo "has_changes=false" >> "$GITHUB_OUTPUT" - echo "No locale changes detected." - else - echo "has_changes=true" >> "$GITHUB_OUTPUT" - git diff --cached --binary -- lang > locale.patch - fi - - - name: Report no changes - if: steps.locale-changes.outputs.has_changes == 'false' - run: | - { - echo "## Locale update result" - echo - echo 'No changes detected in `lang/**/*.php`.' - echo "PR creation was skipped." - } >> "$GITHUB_STEP_SUMMARY" - - - name: Upload locale patch - if: steps.locale-changes.outputs.has_changes == 'true' - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 - with: - name: locale-patch - path: locale.patch - - create-locales-pr: - name: Create locales PR - runs-on: ubuntu-latest - needs: pull-locales - if: needs.pull-locales.outputs.has_changes == 'true' - permissions: - contents: write - pull-requests: write - - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - fetch-depth: 2 - persist-credentials: false - - name: Download locale patch - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 - with: - name: locale-patch - - name: Apply locale patch - run: git apply --index locale.patch - - name: Create Pull Request - uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1 - with: - commit-message: Update locales - add-paths: "lang/**/*.php" - branch: update-locales - title: Update locales using POEditor - body: This PR was automatically created using the most recent translations from POEditor. diff --git a/.github/workflows/update-bbb-recording-player.yml b/.github/workflows/update-bbb-recording-player.yml deleted file mode 100644 index 6a079eb7ca..0000000000 --- a/.github/workflows/update-bbb-recording-player.yml +++ /dev/null @@ -1,78 +0,0 @@ -name: BBB Recording Player Updates - -on: - schedule: - - cron: "0 0 * * *" # Run every day at midnight - -permissions: - contents: read - -jobs: - check-for-updates: - name: Check for BBB Recording Player Updates - runs-on: ubuntu-latest - permissions: - contents: write - pull-requests: write - - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - fetch-depth: 2 - persist-credentials: false - - name: Get the latest BBB Recording Player release - run: | - curl --fail --silent --show-error --location \ - --retry 5 --retry-all-errors --retry-delay 2 \ - --header "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ - --url "https://api.github.com/repos/bigbluebutton/bbb-playback/releases/latest" \ - -o player-release.json - - name: Extract the latest BBB Recording Player version - run: echo "LATEST_PLAYER_VERSION=$(jq -r '.tag_name' player-release.json | sed 's/^v//')" >> $GITHUB_ENV - - name: Extract release notes - run: jq -r '.body // ""' player-release.json > player-release-notes.md - - name: Extract the current BBB Recording Player version from Docker file - run: echo "CURRENT_PLAYER_VERSION=$(sed -n 's/ARG PLAYBACK_PLAYER_VERSION=//p' docker/app/Dockerfile)" >> $GITHUB_ENV - - name: Compare the versions - run: | - if dpkg --compare-versions "$LATEST_PLAYER_VERSION" gt "$CURRENT_PLAYER_VERSION"; then - echo "NEEDS_UPDATE=true" >> "$GITHUB_ENV" - else - echo "NEEDS_UPDATE=false" >> "$GITHUB_ENV" - fi - env: - LATEST_PLAYER_VERSION: ${{ env.LATEST_PLAYER_VERSION }} - CURRENT_PLAYER_VERSION: ${{ env.CURRENT_PLAYER_VERSION }} - - name: Update the BBB Player version - if: ${{ env.NEEDS_UPDATE == 'true' }} - run: sed -i "s/ARG PLAYBACK_PLAYER_VERSION=.*/ARG PLAYBACK_PLAYER_VERSION=${LATEST_PLAYER_VERSION}/" docker/app/Dockerfile - - name: Prepare PR body file - if: ${{ env.NEEDS_UPDATE == 'true' }} - run: | - cat > pr-body.md < - Release notes -

Sourced from bigbluebutton/bbb-playback's releases.

- - PR_BODY - cat player-release-notes.md >> pr-body.md - cat >> pr-body.md <<'PR_BODY' - - - - ## Automated Update - This PR was automatically generated by the BBB Recording Player update workflow. - PR_BODY - - name: Create PR with the update - if: ${{ env.NEEDS_UPDATE == 'true' }} - uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1 - with: - add-paths: "docker/app/Dockerfile" - commit-message: "Update BBB Recording Player to version ${{ env.LATEST_PLAYER_VERSION }}" - title: "Bump BBB Recording Player from ${{ env.CURRENT_PLAYER_VERSION }} to ${{ env.LATEST_PLAYER_VERSION }}" - labels: "dependencies" - body-path: "pr-body.md" - branch: "update-bbb-recording-player-${{ env.LATEST_PLAYER_VERSION }}" diff --git a/.github/workflows/update-publiccode-on-release.yml b/.github/workflows/update-publiccode-on-release.yml deleted file mode 100644 index 0ac70a8155..0000000000 --- a/.github/workflows/update-publiccode-on-release.yml +++ /dev/null @@ -1,52 +0,0 @@ -name: Update publiccode.yml on release - -on: - release: - types: [published] - -permissions: - contents: write - pull-requests: write - -jobs: - update-publiccode: - runs-on: ubuntu-latest - - steps: - - name: Checkout develop branch - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - ref: develop - persist-credentials: false - - - name: Extract release version and date - id: release - run: | - RAW_VERSION="${GITHUB_REF#refs/tags/}" - VERSION="${RAW_VERSION#v}" # strip leading 'v' - RELEASE_DATE=$(date -u +"%Y-%m-%d") - - echo "version=$VERSION" >> "$GITHUB_OUTPUT" - echo "date=$RELEASE_DATE" >> "$GITHUB_OUTPUT" - - - name: Update publiccode.yml - run: | - sed -i "s/^softwareVersion:.*/softwareVersion: \"${VERSION}\"/" publiccode.yml - sed -i "s/^releaseDate:.*/releaseDate: \"${RELEASE_DATE}\"/" publiccode.yml - env: - VERSION: ${{ steps.release.outputs.version }} - RELEASE_DATE: ${{ steps.release.outputs.date }} - - - name: Create PR with the update - uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1 - with: - add-paths: "publiccode.yml" - commit-message: "Update publiccode.yml to version ${{ steps.release.outputs.version }}" - title: "Update publiccode.yml to version ${{ steps.release.outputs.version }}" - labels: "publiccode" - body: | - Update publiccode.yml to version ${{ steps.release.outputs.version }} - - ## Automated Update - This PR was automatically generated by the "update publiccode.yml on release" workflow. - branch: "update-publiccode" diff --git a/.github/workflows/upload-locales.yml b/.github/workflows/upload-locales.yml deleted file mode 100644 index cbd5527e8e..0000000000 --- a/.github/workflows/upload-locales.yml +++ /dev/null @@ -1,94 +0,0 @@ -name: Upload locales to POEditor - -on: - workflow_dispatch: - inputs: - poeditor_project_id: - required: true - description: "POEditor Project ID" - type: number - push: - branches: - - "develop" - -permissions: - contents: read - -env: - PHP_VERSION: 8.5 - -jobs: - pull-locales: - name: Upload locales to POEditor - runs-on: ubuntu-latest - - services: - mariadb: - image: mariadb:11 - ports: - - 3306 - env: - MARIADB_USER: user - MARIADB_PASSWORD: password - MARIADB_DATABASE: test - MARIADB_ROOT_PASSWORD: password - options: --health-cmd="healthcheck.sh --connect --innodb_initialized" --health-interval=5s --health-timeout=2s --health-retries=3 - - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - fetch-depth: 2 - persist-credentials: false - - name: Verify MariaDB connection - env: - PORT: ${{ job.services.mariadb.ports[3306] }} - run: | - while ! mysqladmin ping -h"127.0.0.1" -P"$PORT" --silent; do - sleep 1 - done - - name: Setup PHP, with composer and extensions - uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # 2.37.0 - with: - php-version: ${{ env.PHP_VERSION }} - extensions: bcmath, ctype, fileinfo, json, mbstring, dom, ldap, pdo, tokenizer, xml, mysql, sqlite - coverage: pcov - - name: Copy .env - run: php -r "copy('.env.ci', '.env');" - - name: Get Composer Cache Directory - id: composer-cache - run: | - echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT - - uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5 - with: - path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} - restore-keys: | - ${{ runner.os }}-composer- - - name: Install php dependencies - run: | - composer self-update - composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist - - name: Generate key - run: php artisan key:generate - - name: Directory Permissions - run: chmod -R 777 storage bootstrap/cache - - name: Migrate Database - env: - DB_HOST: 127.0.0.1 - DB_PORT: ${{ job.services.mariadb.ports[3306] }} - DB_DATABASE: test - DB_USERNAME: root - DB_PASSWORD: password - run: php artisan migrate --no-interaction -vvv --force - - - name: Execute command to push locales from POEditor - env: - DB_HOST: 127.0.0.1 - DB_PORT: ${{ job.services.mariadb.ports[3306] }} - DB_DATABASE: test - DB_USERNAME: root - DB_PASSWORD: password - POEDITOR_TOKEN: ${{ secrets.POEDITOR_TOKEN }} - POEDITOR_PROJECT: ${{ github.event.inputs.poeditor_project_id || secrets.POEDITOR_PROJECT}} - run: php artisan locales:upload diff --git a/.github/workflows/virtuos-docker.yml b/.github/workflows/virtuos-docker.yml new file mode 100644 index 0000000000..26dd7a28ba --- /dev/null +++ b/.github/workflows/virtuos-docker.yml @@ -0,0 +1,54 @@ +name: virtUOS Docker build + +on: + workflow_dispatch: + pull_request: + +jobs: + build-and-push-image: + runs-on: ubuntu-latest + permissions: + contents: read + packages: write + + steps: + - name: Checkout repository + uses: actions/checkout@v6 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v4 + + - name: Log in to the Container registry + uses: docker/login-action@v4 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - name: Set version to tag name + if: ${{ github.event_name == 'release' }} + run: echo "${GITHUB_REF_NAME}" > version + + - name: Set version to commit short hash + if: ${{ github.event_name != 'release' }} + run: echo "${GITHUB_SHA}" | cut -c1-7 > version + + - name: downcase REPO + run: | + echo "IMAGE_NAME=$(echo ${{ github.repository }} | tr '[:upper:]' '[:lower:]')" >> $GITHUB_ENV + + - name: Set image tag + run: | + # head_ref is only set on pull_request events; fall back to ref_name + REF="${{ github.head_ref || github.ref_name }}" + # Replace slashes and other invalid Docker tag characters with dashes + TAG=$(echo "$REF" | tr '/' '-' | sed 's/[^a-zA-Z0-9._-]/-/g' | tr '[:upper:]' '[:lower:]') + echo "IMAGE_TAG=$TAG" >> $GITHUB_ENV + + - name: Build and push Docker image + uses: docker/build-push-action@v7 + with: + file: docker/app/Dockerfile + context: . + push: true + tags: "ghcr.io/${{ env.IMAGE_NAME }}:${{ env.IMAGE_TAG }}" diff --git a/.github/workflows/zizmor.yml b/.github/workflows/zizmor.yml deleted file mode 100644 index d03ef38b9c..0000000000 --- a/.github/workflows/zizmor.yml +++ /dev/null @@ -1,24 +0,0 @@ -name: GitHub Actions Security Analysis with zizmor - -on: - push: - branches: ["develop"] - pull_request: - branches: ["**"] - -permissions: {} - -jobs: - zizmor: - name: Run zizmor - runs-on: ubuntu-latest - permissions: - security-events: write # Required for upload-sarif (used by zizmor-action) to upload SARIF files. - steps: - - name: Checkout repository - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - persist-credentials: false - - - name: Run zizmor - uses: zizmorcore/zizmor-action@b1d7e1fb5de872772f31590499237e7cce841e8e # v0.5.3 diff --git a/CHANGELOG.md b/CHANGELOG.md index d83e7b1eb6..f83da4dfa1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -717,6 +717,7 @@ You can find the changelog for older versions there [here](https://github.com/TH [#2279]: https://github.com/THM-Health/PILOS/pull/2279 [#2281]: https://github.com/THM-Health/PILOS/pull/2281 [#2282]: https://github.com/THM-Health/PILOS/pull/2282 +<<<<<<< HEAD [#2304]: https://github.com/THM-Health/PILOS/pull/2304 [#2313]: https://github.com/THM-Health/PILOS/issues/2313 [#2319]: https://github.com/THM-Health/PILOS/pull/2319 @@ -750,6 +751,7 @@ You can find the changelog for older versions there [here](https://github.com/TH [#2664]: https://github.com/THM-Health/PILOS/issues/2664 [#2665]: https://github.com/THM-Health/PILOS/pull/2665 [#2686]: https://github.com/THM-Health/PILOS/pull/2686 +<<<<<<< HEAD [#2726]: https://github.com/THM-Health/PILOS/pull/2726 [#2728]: https://github.com/THM-Health/PILOS/pull/2728 [#2742]: https://github.com/THM-Health/PILOS/pull/2742 @@ -776,6 +778,7 @@ You can find the changelog for older versions there [here](https://github.com/TH [#2857]: https://github.com/THM-Health/PILOS/pull/2857 [#2873]: https://github.com/THM-Health/PILOS/issues/2873 [#2874]: https://github.com/THM-Health/PILOS/pull/2874 +<<<<<<< HEAD [#2877]: https://github.com/THM-Health/PILOS/issues/2877 [#2879]: https://github.com/THM-Health/PILOS/issues/2879 [#2880]: https://github.com/THM-Health/PILOS/pull/2880 diff --git a/app/Auth/ExternalUser.php b/app/Auth/ExternalUser.php index 8d27e9561d..b02a881903 100644 --- a/app/Auth/ExternalUser.php +++ b/app/Auth/ExternalUser.php @@ -112,9 +112,16 @@ public function validate() foreach ($requiredAttributes as $attribute) { if ($this->getFirstAttributeValue($attribute) == null) { - Log::error('Required attribute missing', ['attribute' => $attribute, 'attributes' => $this->getAttributes()]); - - throw new MissingAttributeException($attribute); + if ($attribute === 'first_name') { + // Set "first_name" to a single space if it's missing + $this->addAttributeValue('first_name', '🤖'); + } else { + Log::error('Required attribute missing', [ + 'attribute' => $attribute, + 'attributes' => $this->getAttributes() + ]); + throw new MissingAttributeException($attribute); + } } } } diff --git a/app/Models/Room.php b/app/Models/Room.php index 4c2bf03f3b..ce6469ff54 100644 --- a/app/Models/Room.php +++ b/app/Models/Room.php @@ -104,6 +104,7 @@ protected function casts() 'lobby' => [ 'cast' => RoomLobby::class, 'expert' => true, + 'only' => [RoomLobby::ENABLED, RoomLobby::DISABLED], ], 'visibility' => [ 'cast' => RoomVisibility::class, @@ -318,7 +319,7 @@ public function getRole(?User $user, ?RoomPersonalizedLink $personalizedLink): R return $personalizedLink->role; } - return RoomUserRole::GUEST; + return $this->getRoomSetting('default_role'); } if ($this->owner->is($user) || $user->can('rooms.manage')) { diff --git a/resources/js/components/RoomJoinButton.vue b/resources/js/components/RoomJoinButton.vue index 3b9f06922e..bd43ebc092 100644 --- a/resources/js/components/RoomJoinButton.vue +++ b/resources/js/components/RoomJoinButton.vue @@ -39,7 +39,7 @@ {{ $t("app.errors.room_already_running") }} -
+