0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

distroless node18 でshellでログインしてnodeコマンドを実行する

0
Posted at

ソースはdistrolessのexamples
https://github.com/GoogleContainerTools/distroless/tree/main/examples/nodejs

debugタグのイメージを利用する。

FROM gcr.io/distroless/nodejs18-debian11:debug

entrypointにshを指定してログインする。

docker run -p 8000:8000 --entrypoint=sh -it  local/node-distroless-http

backendで実行してみる。

 /nodejs/bin/node hello_http.js &

URLにアクセスする。
http://127.0.0.1:8000/

image.png

参考にさせていただきました。
https://qiita.com/taquaki-satwo/items/f8fbe8b1efc4b2323ae7

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?