-
Notifications
You must be signed in to change notification settings - Fork 357
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
Github actions too slow. #127
Comments
You don’t need to run “npm ci” - the GitHub action already runs it for you by default. It also caches the node modules and cypress binary folder so it should not spend more than a few seconds to restore previous cache and do npm ci
…Sent from my iPhone
On Apr 25, 2020, at 21:22, alessandroAmedei ***@***.***> wrote:
The problem is that the action on Github is too slow, because npm ci it has to install Cypress modules which takes several minutes.
This is my configuration of the action
`name: End-to-end tests
on: [push]
jobs:
cypress-run:
runs-on: windows-latest
steps:
- name: Checkout
uses: ***@***.***
- name: Cypress run
uses: ***@***.***
with:
build: npm ci
run: npm run build --if-present
start: npm run serve --prefix frontend
wait-on: http://localhost:8080
serve: npm test_cypress`
Another problem that i have is that npm run serve, is running actually a vue service with vue-cli-service which it can not be found.
The project is like this structured:
-cypress
-backend
-frontend
--package.json --> here i have defined "start": "vue-cli-service serve"
-package.json
that's the frontend/package.json
{ "name": "**", "version": "0.1.0", "private": true, "scripts": { "serve": "vue-cli-service serve", "build": "vue-cli-service build", "test:unit": "vue-cli-service test:unit", "test:e2e": "vue-cli-service test:e2e", "lint": "vue-cli-service lint" }, "dependencies": { ***@***.***/android": "^2.0.1", ***@***.***/cli": "^2.0.1", ***@***.***/core": "^2.0.1", ***@***.***/vue-qrcode": "^1.0.2", "axios": "^0.19.2", "core-js": "^3.6.4", "dateformat": "^3.0.3", "leaflet": "^1.6.0", "material-design-icons-iconfont": "^5.0.1", "register-service-worker": "^1.6.2", "vue": "^2.6.11", "vue-router": "^3.1.5", "vue2-leaflet": "^2.5.2", "vuetify": "^2.2.11", "vuex": "^3.1.3" }, "devDependencies": { ***@***.***/cli-plugin-babel": "~4.2.0", ***@***.***/cli-plugin-e2e-cypress": "~4.2.0", ***@***.***/cli-plugin-eslint": "~4.2.0", ***@***.***/cli-plugin-pwa": "~4.2.0", ***@***.***/cli-plugin-router": "~4.2.0", ***@***.***/cli-plugin-unit-jest": "~4.2.0", ***@***.***/cli-plugin-vuex": "~4.2.0", ***@***.***/cli-service": "~4.2.0", ***@***.***/test-utils": "1.0.0-beta.31", "babel-eslint": "^10.0.3", "eslint": "^6.7.2", "eslint-plugin-vue": "^6.1.2", "sass": "^1.19.0", "sass-loader": "^8.0.0", "vue-cli-plugin-vuetify": "~2.0.5", "vue-template-compiler": "^2.6.11", "vuetify-loader": "^1.3.0" }, "eslintConfig": { "root": true, "env": { "node": true }, "extends": [ "plugin:vue/essential", "eslint:recommended" ], "parserOptions": { "parser": "babel-eslint" }, "rules": {}, "overrides": [ { "files": [ "**/__tests__/*.{j,t}s?(x)", "**/tests/unit/**/*.spec.{j,t}s?(x)" ], "env": { "jest": true } } ] }, "browserslist": [ "> 1%", "last 2 versions" ], "jest": { "preset": ***@***.***/cli-plugin-unit-jest" } }
this is the /package.json
{
"name": "",
"version": "1.0.1",
"description": "",
"main": "backend/index.js",
"scripts": {
"start": "node backend/index.js",
"test": "mocha backend/test --recursive --exit",
"dev": "nodemon backend/index.js",
"test_cypress": "cypress run --record --key 16f8412b-c1f7-4e24-926d-8fb241c059cc"
},
"author": ***@***.***",
"license": "ISC",
"dependencies": {
"bcryptjs": "^2.4.3",
"chai-http": "^4.3.0",
"dateformat": "^3.0.3",
"express": "^4.17.1",
"express-mung": "^0.5.1",
"jsonwebtoken": "^8.5.1",
"leaflet": "^1.6.0",
"mongoose": "^5.9.7",
"nodemailer": "^6.4.6",
"nodemon": "^2.0.3",
"serve-static": "^1.14.1",
"vue2-leaflet": "^2.5.2",
"web-push": "^3.4.3"
},
"devDependencies": {
"chai": "^4.2.0",
"cypress": "^4.4.1",
"mocha": "^7.1.1",
"mockgoose": "^8.0.4",
"supertest": "^4.0.2"
}
}
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
Thank you! |
Or, i could use |
I know it is a really bad idea, but I tried like this, i commited also node_modules for the frontend vue app, and it works! I can run with the vue-cli-service the http dev server. |
Opened a new issue #128 |
Is there a way we can improve I tried to cache the Thanks! |
The problem is that the action on Github is too slow, because
npm ci
it has to install Cypress modules which takes several minutes.This is my configuration of the action
Another problem that i have is that npm run serve, is running actually a vue service with vue-cli-service which it can not be found.
The project is like this structured:
-cypress
-backend
-frontend
--package.json --> here i have defined "start": "vue-cli-service serve"
-package.json
that's the frontend/package.json
this is the /package.json
The text was updated successfully, but these errors were encountered: