DenoDDeno
Powered by
Captain π—•π—˜π—˜π—™πŸ₯©C
Denoβ€’3y agoβ€’
4 replies
Captain π—•π—˜π—˜π—™πŸ₯©

Can use the --cert flag in the command line, but not in deno.json

I am trying to run my deno program with the following command:
deno run -A --cert ~/tmp/ca.crt main.ts
deno run -A --cert ~/tmp/ca.crt main.ts

This works fine. However, if I put this command in my
deno.json
deno.json
, it can no longer find the certificate:

An error occurred during route handling or page rendering. Error: Failed opening CA file: No such file or directory (os error 2)
An error occurred during route handling or page rendering. Error: Failed opening CA file: No such file or directory (os error 2)


My
deno.json
deno.json
relevant line:

"start": "deno run -A --cert=/home/jlcarveth/tmp/ca.crt --watch=static/,routes/ dev.ts"
"start": "deno run -A --cert=/home/jlcarveth/tmp/ca.crt --watch=static/,routes/ dev.ts"


So why can Deno find the cert no problem if I run the command from the CLI, but not via deno.json?
Deno banner
DenoJoin
Chat about Deno, a modern runtime for JavaScript and TypeScript.
20,944Members
Resources
Recent Announcements

Similar Threads

Was this page helpful?

Similar Threads

Deno Deploy --cert flag
bera.funBbera.fun / help
4y ago
`deno add` does not support the --cert option and does not use `$DENO_CERT`
Jan-MagnusJJan-Magnus / help
2y ago
In nextjs, how to use deno.json.
hhhhhxxxHhhhhhxxx / help
16mo ago
HTTPS custom cert passphrase in Deno?
abiAabi / help
3y ago