-
Notifications
You must be signed in to change notification settings - Fork 5
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
Generic Node.js build task #503
Comments
@henninggross @netzartist what do you think? I am fine with this.
Basically what you are proposing is to have a param like |
I guess we can even live without customization. Simplest solution would be to provide a dummy build task, e.g.
and vice versa for I haven't thought about a proper integration of cypress capabilies yet. But what you said about different customization sounds good to me. |
I like this workaround! So in my eyes, this issue is then just about renaming the task. I see the following options:
I lean towards For Cypress, I think it would be great to have a FAQ entry how to add this. The place to add it is in those wrapper Dockerfiles, but it would be nice to have a concrete example. |
Renaming to |
https://github.com/opendevstack/ods-pipeline/blob/master/build/package/Dockerfile.node16-typescript-toolset and https://github.com/opendevstack/ods-pipeline/blob/master/build/package/scripts/build-typescript.sh actually doesn't contain anything TypeScript-specific. The way how it is written is already pretty generic.
build-typescript.sh
for example awaits certain tasks to exist within thepackage.json
and also certain artifacts to be created. But tasks like build or test would exist in a lot of Node.js-based projects regardless of TypeScript beeing in or out. Also the linting is done with eslint which works for TypeScript as well as plain JavaScript.I'd propose to treat it generic for any Node.js-based app and rename it to
... builds Node.js-based applications ...
,build-nodejs.sh
, etc.In addition I'd propose to provide minimalistic configuration possibilities for the tasks to run. Right now it is
npm run build
andnpm run test
, but certain usecases like the e2e-cypress (see also https://github.com/opendevstack/ods-quickstarters/blob/master/e2e-cypress/Jenkinsfile.template) would be fine with justnpm run test
.If you like, I'd also be happy to contribute this proposal as an ADR 😉
The text was updated successfully, but these errors were encountered: