generator-jhipster: Daily builds: JDL microservices broken with OAuth2+Cypress
Overview of the issue
See https://github.com/hipster-labs/jhipster-daily-builds
The daily builds for JDL Microservices + OAuth2 + Cypress are broken since days
Motivation for or Use Case
Reproduce the error
Related issues
Suggest a Fix
JHipster Version(s)
JHipster configuration
Entity configuration(s) entityName.json files generated in the .jhipster directory
Browsers and Operating System
- Checking this box is mandatory (this is just to show you read everything)
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 17 (17 by maintainers)
An update. I have tracked down the issue. And a fix is in the works.
Without application inside docker, keycloak is reached by localhost:9080 everywhere.
With docker:
keycload:9080. So: 1 - we need to update cypress.json with keycloak endpoint. 2 - once we update cypress.json we are affected by https://github.com/cypress-io/cypress/issues/944 like @SudharakaP suggested.Fixes:
After few days, your PR seems to fix the main problem, @mshima : good job !!!
There is still another problem, related to Registry, which doesn’t start in time:
I’m fixing this last part
@mshima : Thanks a lot for the detailed analysis. Seems like the daily builds are fixed. 👍🏼
@mshima : I am, and was trying different things; but kinda out of ideas right now. 😢
EDIT: If you have any ideas or want to work on it please feel free to take it. 😄
@SudharakaP are you working on this?
@SudharakaP : yes, it’s related to Cypress, as it works approximatively well with protractor (but with some random failures)
@pascalgrimaud : Interestingly enough I think we didn’t used to run the e2e tests when things were passing before; for example; https://github.com/hipster-labs/jhipster-daily-builds/runs/1127373854?check_suite_focus=true. Although just switching to Protractor and running the e2e seems to fix the issue; which probably means I think this is a mis-configuration in Cypress.
Run with Protractor in my fork: https://github.com/SudharakaP/jhipster-daily-builds/runs/1227102969?check_suite_focus=true
yes plz, @SudharakaP
Here some very quick analyze:
for JDLMs in GitHub Actions, the registry started at the same time than Keycloak, and Keycloak took approximatively 20sec to be “up”, so the registry failed and is not up, so the other services can’t start as the registry is not up
once, this 1st bug is fixed, Cypress can’t access to Keycloak for unknown reason -> I manage to reproduce the issue locally. Maybe because cypress.json has “localhost:9080” hard coded, and here, we should use “keycloak:9080”
Easy to reproduce locally:
I can take a look at this issue if no one is on it already. 😄