D
Deno

help

Fresh in a Docker exiting process

Kkushranada3/5/2023
Not sure whats going wrong. Works fine on deno deploy. But when trying to run it inside a docker container the process exits shortly after starting. https://github.com/Robspin/deno-fresh-blog My Dockerfile:
FROM denoland/deno:1.31.1

ARG GIT_REVISION
ENV DENO_DEPLOYMENT_ID=${GIT_REVISION}

WORKDIR /app

COPY . .
RUN deno cache main.ts --import-map=import_map.json

EXPOSE 8000

CMD ["task", "production"]
FROM denoland/deno:1.31.1

ARG GIT_REVISION
ENV DENO_DEPLOYMENT_ID=${GIT_REVISION}

WORKDIR /app

COPY . .
RUN deno cache main.ts --import-map=import_map.json

EXPOSE 8000

CMD ["task", "production"]
Does anyone have any thoughts or similar experience?
GitHub
GitHub - Robspin/deno-fresh-blog
Contribute to Robspin/deno-fresh-blog development by creating an account on GitHub.
UUUnknown User3/5/2023
Message Not Public
Sign In & Join Server To View
Kkushranada3/5/2023
Yes it logs the CMD: Task production deno run -A main.ts And then nothing. It just says EXITED(1) Its as if the container doesnt stay alive by the await start in main.ts...
UUUnknown User3/5/2023
2 Messages Not Public
Sign In & Join Server To View
Kkushranada3/5/2023
I think since the base image is deno, the CMD automatically uses deno. I tried adding deno in the CMD but it behaves the same; it runs the command then immediately exits with code (1).
UUUnknown User3/5/2023
Message Not Public
Sign In & Join Server To View
Kkushranada3/5/2023
I copy pasted the docker example from the Fresh docs. I think something might be going wrong dependency related. But I have no idea how to debug this as I dont get any errors and it works fine locally without a container and on deno deploy.
UUUnknown User3/5/2023
Message Not Public
Sign In & Join Server To View

Looking for more? Join the community!

Recommended Posts
eval script with stricter permissions in denoHi all, I wanted to know if its possible to eval a script in deno with more strict permissions. Somesolid-js with DenoI was wondering if it was possible to use solid-js with Deno natively without something like esbuildFeature Suggestion: Dark Mode for `std` library Docs.Deno's documentation is great. I find myself reading it more and more. I currently use a browser addRunning esbuild with esbuild_deno_loaderI've spent probably four or five hours trying to track down this issue, to the point where I actuall`fetch` request always fails onceHello, I got a script containing a `fetch` request. Once in a while, it throws the `connection closeSequentially write to TPC connectionHey, I experience errors when multiple async functions write to a TCP (`Deno.Conn`) connection. How I'd like to change the background colour of the `body` element in Fresh. How do I do that simply?(see title)Deno process watcher. How?This code when compile, runs a simple http server. ```ts import { serve } from "https://deno.land/stmonaco-editor on freshHello. First of all, I am a newbie in web development. I played around with Deno for a while. So I tdeno in Dockerfilei have successfully installed deno with theese commands: ``` # install denojs RUN curl -fsSL https:could not find npm package forI'm trying to make Hardhat CLI work with Deno but I stumbled upon this error which comes from Deno: Microsoft Transact SQLIs there official Deno driver for this or a recommended way?Remove std/node, it was merged into Deno itself (#3206)This used to work, but now it doesn't. Where do you show examples of where this was moved to and howFFI Difference between buffer and pointerI’ve been using interchangeably `Deno.UnsafePointer.of(new Uint8Array())` with type `pointer` and `nDetecting invalid JS stringsIs there any built-in way to "detect" invalid strings? Here's an example: ```ts // this is an invaError connecting to MongoDB AtlasHello, I'm trying to connect to MongoDB Atlas via `mongoose` (`npm:mongoose`) but encountered the fointeract with deno Extension at runtimeIs there any way to interact with an extension at code execution? I need to pass a pointer from my rAny good way to modify remote url file and debug it?For example, I'm using `import server "https://deno.land/x/ultra@v2.1.7/server.ts"` I want to modifyCache related headers not included in deno deploy for static file servingI have a hello world level static site using `serveDir`. When I run the site locally I see that WeakError with relativ import path after "deno install"Is it possible that imports in deno.json are ignored after "deno install"? ```bash deno run ./my-