Skip to content
This repository was archived by the owner on Nov 23, 2026. It is now read-only.
This repository was archived by the owner on Nov 23, 2026. It is now read-only.

[QA] run e2e tests with external idp (keycloak) in CI #10458

Closed

Description

@saw-jan

Description

e2e tests can run with keycloak as an IDP (Done at #9904). So now, we want to have e2e tests running with keycloak setup in CI.

Motivation

Previously, we found bugs related to Ocis with external IDP like this one owncloud/ocis#8074. Issues related to OCIS with external IDP are not possible to find out as early as possible. And only can be found when playing around manually.

Since we have e2e tests that can run with keycloak idp, bugs like that can be found early if we have automated tests running in CI.

NOTE: currently, there are no docs on running tests with keycloak. But here are the available envs:

web/tests/e2e/config.js

Lines 9 to 14 in 71cbae4

// keycloak config
keycloak: process.env.KEYCLOAK === 'true',
keycloakHost: process.env.KEYCLOAK_HOST ?? 'keycloak.owncloud.test',
keycloakRealm: process.env.KEYCLOAK_REALM ?? 'oCIS',
keycloakAdminUser: process.env.KEYCLOAK_ADMIN_USER ?? 'admin',
keycloakAdminPassword: process.env.KEYCLOAK_ADMIN_PASSWORD ?? 'admin',

Open Tasks

  • Filter out e2e test suites to run with keycloak (We may want to run only the few selected scenarios)
  • Bring e2e-with-keycloak to Drone CI
    • run nightly and with full-ci only

CC @ScharfViktor

Todo

Failure On CI

  • when running space.feature in CI, tests fail at the login step (change role to space admin from user using api and login). While users try to log in web-ocis the API request related to /v1.0/drive fails with 500 status code. Tried to reproduce locally by setting low memory usage in docker.
    CPU = 1
traefik ocis postgres Keycloak result
520 520 520 520 passed
250 128 250 300 passed
20 100 20 250 passed
128 50 200 250 fail => while login capabilities api return 500 status code
50 90 80 300 fail => while login capabilities api return 500 status code
50 90 20 300 fail => logout timeout error

Research outcome

High chance of memory limit causing CI to fail

Activity

  1. amrita-shrestha commented on Feb 14, 2024

    @amrita-shrestha
    Contributor

    @PrajwolAmatya and @saw-jan i need some basic info how do we run test and keycloak before

  2. PrajwolAmatya commented on Feb 14, 2024

    @PrajwolAmatya
    Contributor

    I used to run as follow:

    ### on oCIS repo
    goto: deployments/examples/ocis_keycloak
    run: docker compose up
    
    ### first login to
    https://keycloak.owncloud.test
    
    ### then login to
    https://ocis.owncloud.test
    run e2e test:
    BASE_URL_OCIS=ocis.owncloud.test KEYCLOAK=ture pnpm run test:e2e:cucumber tests/e2e/cucumber/features/smoke/copyMove.feature:6
  3. saw-jan commented on Feb 14, 2024

    @saw-jan
    MemberAuthor

    @PrajwolAmatya and @saw-jan i need some basic info how do we run test and keycloak before

    currently, we do not have any docs related to that. but here are the available envs:

    web/tests/e2e/config.js

    Lines 9 to 14 in 71cbae4

    // keycloak config
    keycloak: process.env.KEYCLOAK === 'true',
    keycloakHost: process.env.KEYCLOAK_HOST ?? 'keycloak.owncloud.test',
    keycloakRealm: process.env.KEYCLOAK_REALM ?? 'oCIS',
    keycloakAdminUser: process.env.KEYCLOAK_ADMIN_USER ?? 'admin',
    keycloakAdminPassword: process.env.KEYCLOAK_ADMIN_PASSWORD ?? 'admin',

  4. amrita-shrestha commented on Feb 14, 2024

    @amrita-shrestha
    Contributor

    @PrajwolAmatya and @saw-jan i need some basic info how do we run test and keycloak before

    currently, we do not have any docs related to that. but here are the available envs:

    web/tests/e2e/config.js

    Lines 9 to 14 in 71cbae4

    // keycloak config
    keycloak: process.env.KEYCLOAK === 'true',
    keycloakHost: process.env.KEYCLOAK_HOST ?? 'keycloak.owncloud.test',
    keycloakRealm: process.env.KEYCLOAK_REALM ?? 'oCIS',
    keycloakAdminUser: process.env.KEYCLOAK_ADMIN_USER ?? 'admin',
    keycloakAdminPassword: process.env.KEYCLOAK_ADMIN_PASSWORD ?? 'admin',

    i have already seen that I just want to know if we already had docs of setup for testing it against the local setup but nevermind i will look over it

  5. removed their assignment
    on Jun 4, 2024
  6. nabim777 commented on Jun 20, 2024

    @nabim777
    Member

    All tasks are completed, so closing this issue.

  7. removed their assignment
    on Jun 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions