Run remote Fresh application code locally.
Is it possible to run a remotely hosted Fresh application? E.g. I'm attempting to do
deno run -A https://raw.githubusercontent.com/cknight/dev-tools/main/main.ts
but this isn't working as the deno.json
file isn't loading and so the import map isn't either. I've also tried using the --config
flag, but it only seems to support local files. I'm guessing to support this I would need to rework the application to remove the deno.json
file?
Use case: I have an application which processes sensitive data. It's best if the use runs this on their own machine, rather than a centrally hosted instance. While the user could clone the repo and run deno task start
, a single (albeit, long) command line to run the application locally is attractive.11 Replies
Remote config files are an open issue. I'd really love to get that one solved.
I've used a copyable Deno install command in the readme.md, and have the user install from there.
At that point the user just runs the command.
For Pyro I have this install script: https://github.com/lino-levan/pyro/blob/main/install.ts
which is definitely a hack
This could all be a lot better if
--config
supported remote configsIn my Hot dev server readme, i have
Sounds like an easy enhancement. I'll have a search for the issue. Thanks!
GitHub
Support remote configuration files · Issue #13488 · denoland/deno
Especially when using a remote main module, it can be very beneficial to support a remote --config/-c file, especially when you want a one liner without pre-installing anything locally.
Ha, I said literally the same thing in the issue.
Haha, that's awesome and love the comment 👍
I've not used the install command before. Will it work if the project has a remote
deno.json
file?Ideally
--config
works with both install and run (they don't work if it's a remote file)Not sure. I don't use deno.json. Ask Lino.
It's a very convenient way to have user install tools/utilities.
I've used two installs for utils; one with --reload, and one without, so you can refresh the install if needed.
Yeah, I think we need Lino's awesome hack to make this work with install. Thanks both.