Code Monkey home page Code Monkey logo

Comments (4)

dperson avatar dperson commented on June 24, 2024 4

@htkoca sorry for the slow reply, I was out of town on vacation.

The -u flag will create a user on the system, for simple authentication needs.

Because this container is designed to be a simple and easy way to share a directory of files, it skips many more advanced features of samba and AD. All file access takes place as the smbuser user and group users. The USERID and GROUPID environment variables will be used for the smbuser and users user/group in the container.

This prevents most permission issues, also as users created in the container won't be created on the host running docker, there are fewer random IDs to deal with there. If you set USERID and GROUPID to a valid user on the docker server, the files will be owned by that user/group.

from samba.

tkodev avatar tkodev commented on June 24, 2024 1

Wait I'm curious: what exactly is the difference between the userid and groupid in -u and in the environment variables USERID and GROUPID?

from samba.

dperson avatar dperson commented on June 24, 2024

This container is a way to quickly and easily setup a simple share. All files are setup to be owned by one user and group (less to synchronize with the docker host). To set the UID and GID set the USERID and GROUPID environment variables. Just set them both to 0 and you should get the results that you want. Hope that helps.

from samba.

 avatar commented on June 24, 2024

It worked! I just thought -e GROUPID=0 -e USERID=0 is equal to -u "root;root;0;0"

from samba.

Related Issues (20)

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.