# Do not upgrade to 2.0.3 # https://github.com/denoland/deno/issues/26583 FROM denoland/deno:2.0.2 WORKDIR /app COPY bot bot COPY cfg cfg COPY core core COPY external external COPY migrations migrations COPY repo repo COPY utils utils COPY deno.json . COPY config.ts . COPY main.ts . RUN deno cache --allow-import ./main.ts RUN mkdir bin # Doesn't work. File read iessues issues # Suppose related to this issue https://github.com/denoland/deno/issues/20885 # ENV MIC_CONFIG_PATH="/app/config.json" # RUN deno compile -o ./mic-bin --allow-all ./main.ts # ENTRYPOINT [ "./mic-bin" ] # TODO: Replace allow all with a normal permissions # https://docs.deno.com/runtime/fundamentals/security/#permissions ENTRYPOINT [ "deno", "run", "--allow-all", "./main.ts" ]