OWASP / threat-dragon

An open source threat modeling tool from OWASP
https://owasp.org/www-project-threat-dragon/
Apache License 2.0
933 stars 251 forks source link

Dockerfile build fails with latest commit (d07479d) (notarytool is not defined) #752

Closed babymarlin closed 1 year ago

babymarlin commented 1 year ago

Describe the bug: Dockerfile build (using docker build -t owasp-threat-dragon:dev .) fails with the following error:

ERROR  ReferenceError: notarytool is not defined

(See below for additional docker build output)

Expected behaviour: The docker build command should complete successfully.

Environment:

To Reproduce: Follow the instructions in README.md to build Docker (local build).

Any additional context, screenshots, etc:

 => ERROR [build 13/13] RUN         npm run build                                                                                                                                                                                2.2s
------
 > [build 13/13] RUN         npm run build:
0.805
0.805 > threat-dragon@2.0.6 build
0.805 > npm-run-all build:vue build:server
0.805
1.292
1.292 > threat-dragon@2.0.6 build:vue
1.292 > cd td.vue && npm run build
1.292
1.587
1.587 > threat-dragon@2.0.6 build
1.587 > vue-cli-service build --no-unsafe-inline
1.587
2.128 Server API protocol: http and port: 3000
2.128 Server API protocol: http and port: 3000
2.130  ERROR  ReferenceError: notarytool is not defined
2.130 ReferenceError: notarytool is not defined
2.130     at Object.<anonymous> (/app/td.vue/vue.config.js:51:27)
2.130     at Module._compile (node:internal/modules/cjs/loader:1256:14)
2.130     at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
2.130     at Module.load (node:internal/modules/cjs/loader:1119:32)
2.130     at Module._load (node:internal/modules/cjs/loader:960:12)
2.130     at Module.require (node:internal/modules/cjs/loader:1143:19)
2.130     at require (node:internal/modules/cjs/helpers:119:18)
2.130     at exports.loadModule (/app/td.vue/node_modules/@vue/cli-shared-utils/lib/module.js:86:14)
2.130     at loadFileConfig (/app/td.vue/node_modules/@vue/cli-service/lib/util/loadFileConfig.js:30:20)
2.130     at Service.loadUserOptions (/app/td.vue/node_modules/@vue/cli-service/lib/Service.js:339:44)
2.152 ERROR: "build:vue" exited with 1.
------
Dockerfile:31
--------------------
  29 |     RUN         cd td.server && npm clean-install
  30 |     RUN         cd td.vue && npm clean-install
  31 | >>> RUN         npm run build
  32 |
  33 |     # Builds the docs
--------------------
ERROR: failed to solve: process "/bin/sh -c npm run build" did not complete successfully: exit code: 1
jgadsden commented 1 year ago

thanks for raising this @babymarlin , I broke the build and forgot to fix it

jgadsden commented 1 year ago

fixed now in commit efac7c68ab5810dd9dbd53bb7d00cd9c05b1d761, thanks again @babymarlin

babymarlin commented 1 year ago

Thanks for fixing this so quickly, @jgadsden.