Giter VIP home page Giter VIP logo

Comments (2)

kevwilde avatar kevwilde commented on July 30, 2024

Other differences between the two images:

There seems to be a disparity when su'ing to the postgres user:

$ docker run -i -t orchardup/postgresql /bin/bash
root@9abd1b3e9be9:/# sudo su - postgres
No directory, logging in with HOME=/
-su: /etc/profile: Permission denied
-su-4.2$ 

vs

docker run -i -t kevwilde/postgresql /bin/bash
root@385d11498119:/# sudo su - postgres
postgres@385d11498119:~$ 

I believe this is the cause of the problem.

Comparing the postgres user:

in orchardup/postgresql:

root@9abd1b3e9be9:/# finger postgres
Login: postgres                 Name: PostgreSQL administrator
Directory: /var/lib/postgresql          Shell: /bin/bash
Never logged in.
No mail.
No Plan.

in kevwilde/postgresql:

root@3c5c32d718ae:/# finger postgres
Login: postgres                 Name: PostgreSQL administrator
Directory: /var/lib/postgresql          Shell: /bin/bash
Never logged in.
No mail.
No Plan.

Other things I checked:

  • postgres users have the same finger output
  • permissions of /var/lib/postgres are identical
  • permissions of /etc/bash.bashrc are identical
  • groups of the postgres user are identical

Finally, the difference is in the permissions of the /etc directory itself:

kevwilde/postgresql:

drwxr-xr-x  86 root root    4096 Jun  5 09:39 etc

orchardup/postgresql:

d--x--x---  77 root root    4096 Jun  5 09:31 etc

I think it might be related to this issue: moby/moby#4068

from docker-postgresql.

kevwilde avatar kevwilde commented on July 30, 2024

It seems to be resolved by adding -s=devicemapper to the DOCKER_OPTS field (ref: https://stackoverflow.com/questions/20810555/ensure-that-docker-is-using-device-mapper-storage-backend)

from docker-postgresql.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.