Coder Social home page Coder Social logo

docker-distroless-deno-example's Introduction

docker-distroless-deno-example

Run deno in distroless container

The result image size is 106MB.

$ docker build . -t deno
Sending build context to Docker daemon  40.45kB
Step 1/7 : FROM alpine:3.9.2
 ---> 5cb3aa00f899
Step 2/7 : RUN apk add --no-cache curl
 ---> Using cache
 ---> a3bf14f3efc4
Step 3/7 : RUN curl -L https://deno.land/x/install/install.sh | sh
 ---> Using cache
 ---> 908da5d0a19f
Step 4/7 : FROM gcr.io/distroless/cc
 ---> e2bb067a7cfa
Step 5/7 : COPY --from=0 /root/.deno/bin/deno /
 ---> Using cache
 ---> ab74cbb23ee6
Step 6/7 : COPY hello.ts /
 ---> Using cache
 ---> ccde535e5a37
Step 7/7 : ENTRYPOINT ["/deno", "hello.ts"]
 ---> Using cache
 ---> eb2dc39a9134
Successfully built eb2dc39a9134
Successfully tagged deno:latest
$ docker run deno
Compiling file:///hello.ts
hello
$ docker image ls deno --format "{{.Size}}"
106MB

docker-distroless-deno-example's People

Contributors

kt3k avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar

docker-distroless-deno-example's Issues

Please Update it not working

error 1 -
docker: Error response from daemon: OCI runtime create failed: container_linux.go:380: starting container process caused: exec: "deno": executable file not found in $PATH: unknown.

error 2-
error: Found argument 'hello.ts' which wasn't expected, or isn't valid in this context

USAGE:
deno [OPTIONS] [SUBCOMMAND]

For more information try --help

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.