Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Continuous Integration build in Jenkins failing due to ChromiumHeadless error #6694

Closed
1 task done
thomastardy opened this issue Nov 16, 2017 · 1 comment
Closed
1 task done
Milestone

Comments

@thomastardy
Copy link
Contributor

thomastardy commented Nov 16, 2017

Overview of the issue

When you generate a new project and setup Continuous Integration in Jenkins based on http://www.jhipster.tech/setting-up-ci/ using the ci-cd sub-generator, the build fails when executing frontend tests.

Error with ChromiumHeadless
14:31:16 [INFO] --- frontend-maven-plugin:1.6:yarn (default-cli) @ pexapark ---
14:31:16 [INFO] Running 'yarn test' in /var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA
14:31:16 [INFO] yarn run v1.3.2
14:31:16 [INFO] $ karma start src/test/javascript/karma.conf.js
14:31:17 [INFO] Hash: e0bdc8cc97632b01d813
14:31:17 [INFO] Version: webpack 3.6.0
14:31:17 [INFO] Time: 60ms
14:31:17 [INFO] webpack: Compiled successfully.
14:31:17 [INFO] webpack: Compiling...
14:31:17 [ERROR] Warning: The 'no-unused-variable' rule requires type infomation.
14:31:17 [INFO] 
14:31:17 [INFO] [at-loader] Using typescript@2.5.2 from typescript and "tsconfig.json" from /var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA/tsconfig.json.
14:31:17 [INFO] 
Post stage
14:31:32 [INFO] 
14:31:32 [INFO] [at-loader] Checking started in a separate process...
14:31:32 [ERROR] 
14:31:32 [ERROR] [at-loader] Checking finished with 7 errors
14:31:32 [ERROR] Hash: 6a1e876e4621b2c10ea5
14:31:32 [INFO] webpack: Failed to compile.
14:31:32 [ERROR] Version: webpack 3.6.0
14:31:32 [ERROR] Time: 12861ms
14:31:32 [ERROR]         Asset     Size  Chunks                    Chunk Names
14:31:32 [ERROR] spec/entry.ts  13.1 MB       0  [emitted]  [big]  spec/entry.ts
14:31:32 [ERROR]    [1] ./node_modules/@angular/core/@angular/core.es5.js 489 kB {0} [built]
14:31:32 [ERROR]   [34] ./node_modules/@angular/core/@angular/core/testing.es5.js 39.7 kB {0} [built]
14:31:32 [ERROR]   [48] ./node_modules/rxjs/Rx.js 9.65 kB {0} [built]
14:31:32 [ERROR]  [365] ./src/test/javascript/spec/entry.ts 853 bytes {0} [built]
14:31:32 [ERROR]  [366] ./node_modules/core-js/index.js 639 bytes {0} [built]
14:31:32 [ERROR]  [554] ./node_modules/zone.js/dist/zone.js 113 kB {0} [built]
14:31:32 [ERROR]  [555] ./node_modules/zone.js/dist/long-stack-trace-zone.js 6.22 kB {0} [built]
14:31:32 [ERROR]  [556] ./node_modules/zone.js/dist/async-test.js 3.23 kB {0} [built]
14:31:32 [ERROR]  [557] ./node_modules/zone.js/dist/fake-async-test.js 16.3 kB {0} [built]
14:31:32 [ERROR]  [558] ./node_modules/zone.js/dist/sync-test.js 1.41 kB {0} [built]
14:31:32 [ERROR]  [559] ./node_modules/zone.js/dist/proxy.js 5.6 kB {0} [built]
14:31:32 [ERROR]  [560] ./node_modules/zone.js/dist/jasmine-patch.js 6.36 kB {0} [built]
14:31:32 [ERROR]  [811] ./node_modules/intl/locale-data/jsonp/en-US.js 24 kB {0} [built]
14:31:32 [ERROR]  [812] ./node_modules/@angular/platform-browser-dynamic/@angular/platform-browser-dynamic/testing.es5.js 3.6 kB {0} [built]
14:31:32 [ERROR]  [816] ./src/test/javascript/spec \.spec 1.2 kB {0} [built]
14:31:32 [ERROR]     + 881 hidden modules
14:31:32 [ERROR] 
14:31:32 [ERROR] WARNING in ./node_modules/@angular/core/@angular/core.es5.js
14:31:32 [ERROR] 5646:15-36 Critical dependency: the request of a dependency is an expression
14:31:32 [ERROR] 
14:31:32 [ERROR] WARNING in ./node_modules/@angular/core/@angular/core.es5.js
14:31:32 [ERROR] 5662:15-102 Critical dependency: the request of a dependency is an expression
14:31:32 [ERROR] 
14:31:32 [ERROR] ERROR in [at-loader] ./src/main/webapp/app/admin/admin.module.ts:16:5 
14:31:32 [ERROR]     TS2305: Module '"/var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA/src/main/webapp/app/admin/index"' has no exported member 'LogsComponent'.
14:31:32 [ERROR] 
14:31:32 [ERROR] ERROR in [at-loader] ./src/main/webapp/app/admin/admin.module.ts:27:5 
14:31:32 [ERROR]     TS2305: Module '"/var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA/src/main/webapp/app/admin/index"' has no exported member 'LogsService'.
14:31:32 [ERROR] 
14:31:32 [ERROR] ERROR in [at-loader] ./src/main/webapp/app/admin/admin.route.ts:8:5 
14:31:32 [ERROR]     TS2305: Module '"/var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA/src/main/webapp/app/admin/index"' has no exported member 'logsRoute'.
14:31:32 [ERROR] 
14:31:32 [ERROR] ERROR in [at-loader] ./src/main/webapp/app/admin/index.ts:15:15 
14:31:32 [ERROR]     TS2307: Cannot find module './logs/logs.component'.
14:31:32 [ERROR] 
14:31:32 [ERROR] ERROR in [at-loader] ./src/main/webapp/app/admin/index.ts:16:15 
14:31:32 [ERROR]     TS2307: Cannot find module './logs/logs.service'.
14:31:32 [ERROR] 
14:31:32 [ERROR] ERROR in [at-loader] ./src/main/webapp/app/admin/index.ts:17:15 
14:31:32 [ERROR]     TS2307: Cannot find module './logs/logs.route'.
14:31:32 [ERROR] 
14:31:32 [ERROR] ERROR in [at-loader] ./src/main/webapp/app/admin/index.ts:18:15 
14:31:32 [ERROR]     TS2307: Cannot find module './logs/log.model'.
14:31:32 [INFO] 16 11 2017 14:31:30.964:INFO [karma]: Karma v1.7.1 server started at http://0.0.0.0:9876/
14:31:32 [INFO] 16 11 2017 14:31:30.965:INFO [launcher]: Launching browser ChromiumHeadlessNoSandbox with unlimited concurrency
14:31:32 [INFO] 16 11 2017 14:31:31.028:INFO [launcher]: Starting browser ChromiumHeadless
14:31:32 [INFO] 16 11 2017 14:31:31.075:ERROR [launcher]: Cannot start ChromiumHeadless
14:31:32 [INFO] 	/var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA/node_modules/puppeteer/.local-chromium/linux-497674/chrome-linux/chrome: error while loading shared libraries: libXss.so.1: cannot open shared object file: No such file or directory
14:31:32 [INFO] 
14:31:32 [INFO] 16 11 2017 14:31:31.075:ERROR [launcher]: ChromiumHeadless stdout: 
14:31:32 [INFO] 16 11 2017 14:31:31.075:ERROR [launcher]: ChromiumHeadless stderr: /var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA/node_modules/puppeteer/.local-chromium/linux-497674/chrome-linux/chrome: error while loading shared libraries: libXss.so.1: cannot open shared object file: No such file or directory
14:31:32 [INFO] 
14:31:32 [INFO] 16 11 2017 14:31:31.087:INFO [launcher]: Trying to start ChromiumHeadless again (1/2).
14:31:32 [INFO] 16 11 2017 14:31:31.104:ERROR [launcher]: Cannot start ChromiumHeadless
14:31:32 [INFO] 	/var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA/node_modules/puppeteer/.local-chromium/linux-497674/chrome-linux/chrome: error while loading shared libraries: libXss.so.1: cannot open shared object file: No such file or directory
14:31:32 [INFO] 
14:31:32 [INFO] 16 11 2017 14:31:31.104:ERROR [launcher]: ChromiumHeadless stdout: 
14:31:32 [INFO] 16 11 2017 14:31:31.104:ERROR [launcher]: ChromiumHeadless stderr: /var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA/node_modules/puppeteer/.local-chromium/linux-497674/chrome-linux/chrome: error while loading shared libraries: libXss.so.1: cannot open shared object file: No such file or directory
14:31:32 [INFO] 
14:31:32 [INFO] 16 11 2017 14:31:31.108:INFO [launcher]: Trying to start ChromiumHeadless again (2/2).
14:31:32 [INFO] 16 11 2017 14:31:31.126:ERROR [launcher]: Cannot start ChromiumHeadless
14:31:32 [INFO] 	/var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA/node_modules/puppeteer/.local-chromium/linux-497674/chrome-linux/chrome: error while loading shared libraries: libXss.so.1: cannot open shared object file: No such file or directory
14:31:32 [INFO] 
14:31:32 [INFO] 16 11 2017 14:31:31.126:ERROR [launcher]: ChromiumHeadless stdout: 
14:31:32 [INFO] 16 11 2017 14:31:31.126:ERROR [launcher]: ChromiumHeadless stderr: /var/lib/jenkins/workspace/ize-web-application-based-o-UXZGC5AKCQEN6TH5Q2MVXJDKCVC5BXOT5QMSO5LCNTW6OJ23ILOA/node_modules/puppeteer/.local-chromium/linux-497674/chrome-linux/chrome: error while loading shared libraries: libXss.so.1: cannot open shared object file: No such file or directory
14:31:32 [INFO] 
14:31:32 [INFO] 16 11 2017 14:31:31.130:ERROR [launcher]: ChromiumHeadless failed 2 times (cannot start). Giving up.
14:31:32 [INFO] 
14:31:32 [INFO] =============================== Coverage summary ===============================
14:31:32 [INFO] Statements   : 100% ( 0/0 )
14:31:32 [INFO] Branches     : 100% ( 0/0 )
14:31:32 [INFO] Functions    : 100% ( 0/0 )
14:31:32 [INFO] Lines        : 100% ( 0/0 )
14:31:32 [INFO] ================================================================================
14:31:32 [ERROR] error Command failed with exit code 1.
14:31:32 [INFO] info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
14:31:32 [INFO] ------------------------------------------------------------------------
14:31:32 [INFO] BUILD FAILURE
Motivation for or Use Case

Generated Jenkinsfile or documentation should be extended/fixed that it works out of the box.

Reproduce the error
  1. Generate sample application
  2. Run ci-cd sub-generator for Jenkins (don't build in docker image)
  3. Start Jenkins with docker-compose and create basic configuration
  4. Create Pipeline Job and execute
Suggest a Fix

Will look into it as soon as I have time.

JHipster Version(s)
pexapark@0.0.0 /Users/tardy/Projects/pexapark/pexapark-mvp
└── generator-jhipster@4.10.2 

JHipster configuration, a .yo-rc.json file generated in the root folder
.yo-rc.json file
{
  "generator-jhipster": {
    "promptValues": {
      "packageName": "com.pexapark.platform"
    },
    "jhipsterVersion": "4.10.2",
    "baseName": "pexapark",
    "packageName": "com.pexapark.platform",
    "packageFolder": "com/pexapark/platform",
    "serverPort": "8080",
    "authenticationType": "jwt",
    "hibernateCache": "ehcache",
    "clusteredHttpSession": false,
    "websocket": false,
    "databaseType": "sql",
    "devDatabaseType": "postgresql",
    "prodDatabaseType": "postgresql",
    "searchEngine": false,
    "messageBroker": false,
    "serviceDiscoveryType": false,
    "buildTool": "maven",
    "enableSocialSignIn": false,
    "enableSwaggerCodegen": false,
    "jwtSecretKey": "replaced-by-jhipster-info",
    "clientFramework": "angularX",
    "useSass": true,
    "clientPackageManager": "yarn",
    "applicationType": "monolith",
    "testFrameworks": [],
    "jhiPrefix": "jhi",
    "enableTranslation": false
  }
}
JDL for the Entity configuration(s) entityName.json files generated in the .jhipster directory
JDL entity definitions

Environment and Tools

java version "1.8.0_151"
Java(TM) SE Runtime Environment (build 1.8.0_151-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.151-b12, mixed mode)

git version 2.15.0

node: v8.9.1

npm: 5.5.1

bower: 1.8.2

gulp:
[15:05:54] CLI version 1.4.0

yeoman: 2.0.0

yarn: 1.3.2

Docker version 17.09.0-ce, build afdb6d4

docker-compose version 1.16.1, build 6d1ac21

Browsers and Operating System

CentOS 7

  • Checking this box is mandatory (this is just to show you read everything)
@jdubois
Copy link
Member

jdubois commented Nov 16, 2017

Closing because of #6567
(and yes, I agree this Chromium migration is annoying!!)

@jdubois jdubois closed this as completed Nov 16, 2017
@jdubois jdubois added this to the 4.11.0 milestone Nov 24, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants