Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cog build instructions and cog dockerfile generation #1585

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

ghost
Copy link

@ghost ghost commented Mar 19, 2024

Use datetime instead of random for dockerfile generation to distinguish older .cog/tmp/buildX from newer .cog/tmp/buildY

…se datetime instead of random to distinguish older .cog/tmp/buildX from newer .cog/tmp/buildY

Signed-off-by: Dhruv Singal <dsingal@nvidia.com>
README.md Outdated
@@ -132,8 +132,7 @@ sudo chmod +x /usr/local/bin/cog
Alternatively, you can build Cog from source and install it with these commands:

```console
make
sudo make install
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why this line removed?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Running sudo make install throws a bunch of errors of go versions required for different go packages. Running make go gave me the built go binary with no issues. I used go 1.22.1 with Ubuntu

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make -- is the same as make cog
sudo make install -- just install cog binary to /usr/local/bin., it is static single file, no go involved.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dsingal0 Let's revert this part for now, since it's not related to the change you're proposing to use meaningful timestamps for temporary build directories. If you're getting unexpected errors when running the current commands, please open an issue and share the error you're seeing.

Copy link
Author

@ghost ghost Mar 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I figured it out, I had a golang 1.18 installed(as a system package) well as 1.22.1(as something on path). sudo make install was calling 1.18 hence the version complaints. make install followed by sudo mv /usr/local/bin worked so I'm reverting this.

pkg/dockerfile/generator.go Outdated Show resolved Hide resolved
gruvNV and others added 2 commits March 19, 2024 17:40
Signed-off-by: Dhruv Singal <dhruvsingalabc@gmail.com>
Co-authored-by: Mattt <mattt@replicate.com>
Signed-off-by: Dhruv Singal <dhruvsingalabc@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants