replicate / cog

Containers for machine learning
https://cog.run
Apache License 2.0
8.1k stars 564 forks source link

cog is broken because of comment in Dockerfile?! #2017

Closed bb1 closed 4 weeks ago

bb1 commented 1 month ago

grafik

> resolve image config for docker-image://docker.io/docker/dockerfile:1.4:
------
Dockerfile:1
--------------------
   1 | >>> #syntax=docker/dockerfile:1.4
   2 |     FROM r8.im/cog-base:cuda12.4-python3.11-torch2.4.1

The generator in this line adds a comment which prevent Docker from running the file: https://github.com/replicate/cog/blob/72d7d50fdc987a601ab617c2910a11af784be6b4/pkg/dockerfile/generator.go#L164 It looks like Docker is interpreting this as the FROM part. Can someone just remove this? Am I the only one affected?

I tried v0.11.3 and v0.11.0 on Ubuntu.

docker --version
Docker version 24.0.7, build 24.0.7-0ubuntu2~22.04.1
nickstenning commented 1 month ago

This isn't an issue with cog. It looks like your docker can't retrieve the metadata about the dockerfile format from docker.io. Have you tried a docker logout and docker login to reauthenticate to docker.io?

nickstenning commented 4 weeks ago

Closing this issue as this isn't a problem with cog.