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

/-/versions for official Docker image returns wrong Datasette version #399

Closed
simonw opened this Issue Jan 11, 2019 · 2 comments

Comments

Projects
None yet
1 participant
@simonw
Copy link
Owner

simonw commented Jan 11, 2019

docker run -p 8001:8001 datasetteproject/datasette datasette -p 8001 -h 0.0.0.0

http://0.0.0.0:8001/-/versions returns this:

{
    "datasette": {
        "version": "0+unknown"
    },
    ...

This is because the Docker image is built by copying in the Datasette source code, which confuses versioneer. Maybe the Docker image should install the code using a wheel or similar?

@simonw simonw added bug minor labels Jan 11, 2019

@simonw

This comment has been minimized.

Copy link
Owner Author

simonw commented Jan 13, 2019

It looks like there are two reasons for this:

  • The .git directory was listed in .dockerignore so it wasn't being copied into the build process
  • The docker build stage wasn't installing the git executable, so it couldn't read the current version

@simonw simonw closed this in a418c8b Jan 13, 2019

@simonw

This comment has been minimized.

Copy link
Owner Author

simonw commented Jan 13, 2019

docker pull datasetteproject/datasette
docker run -p 8001:8001 datasetteproject/datasette datasette -p 8001 -h 0.0.0.0

http://0.0.0.0:8001/-/versions now returns:

{
    "datasette": {
        "version": "0.26.2+0.ga418c8b.dirty"
    },

I'm not sure why it's showing .dirty there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment