How to configure lighthouse ci in gitlab cicd?

孤人 提交于 2021-01-07 02:36:52

问题


I am trying to configure lighthouse report for my angular application, I am configuring in yml file to ensure it will run and create report in gitlab CICD environment. but I am getting an error while it is running in pipeline, have attached the error image, I am new to CI environment, have no idea which causes the issue exactly, is it from configuration or yml file. can anyone help me with this?

.gitlab-ci.yml

step-report-lighthouse:
  image: cypress/browsers:node14.15.0-chrome86-ff82
  stage: lighthouse
  tags:
    - ta_shop_release
  script:
    - npm install
    - npm run build
    - sudo npm install -g @lhci/cli@0.6.x
    - lhci autorun --upload.target=temporary-public-storage --collect.settings.chromeFlags="--no-sandbox" || echo "LHCI failed!"

lighthouserc.js

module.exports = {
    ci: {
        collect: {
            settings: { chromeFlags: '--no-sandbox' },
        },
        upload: {
            target: 'temporary-public-storage',
        },
    },
};

error message

来源:https://stackoverflow.com/questions/65516727/how-to-configure-lighthouse-ci-in-gitlab-cicd

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!