kontainapp / km

Kontain Monitor
http://kontain.app
Apache License 2.0
29 stars 5 forks source link

Images built FROM runenv cannot use Dockerfile RUN #1217

Open msterin opened 3 years ago

msterin commented 3 years ago

Since Docker build does not accept --device or --volume flags, we cannot use RUN in dockerfiles where FROM uses any of Kontain runenv images. This makes Kontainer building supercumbersome

Capturing the issue for discussion //CC @gnode1

As one of the suggestions for discussions, we may just link all for -alpine instead of linking with Kontain runtime. This way the resulting Kontainer will be fully functional in both (km and non-km) worlds. Though we need to think about security implications (e.g. do we expand atttack surface) more, so for now just capturing the point.

msterin commented 3 years ago

We can live with this for a while, with the following guidance to customers (and us)

gnode1 commented 3 years ago

Actually some limited collection of RUN works. And this limitation is consequence of our design.

For now there are some examples (springboot, tensorflow) of busybox based containers. The flow there is two staged dockerfile, with the last stage (the one built on busybox) only doing ADD or COPY. For now this is going to be plan of records, we'll see how it flies. Moving this to know issues.