-
Notifications
You must be signed in to change notification settings - Fork 13
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
Update Docker instructions to include user permissions #19
Conversation
This is a fix for #10
Since the errors with permissions have stopped, I think you're missing the setup for repos. Are they cloned to I just tried going to the ip:port you listed and Firefox gives me an error:
When I try it with curl, I get a response, so it is responsive, just not showing repos.
Can you paste here the exact command you entered to bring up the container? For more testing:
Also paste the output. The contents should be identical to In my testing I've done the following steps: docker host as user gituser with uid and gid of 1001 mkdir -p /mnt/data/rgit/repos
cd /mnt/data/rgit/repos
git clone --bare https://github.com/w4/rgit.git
git clone --bare https://github.com/graskaas/slabs-from-wood.git
git clone --bare https://github.com/iv-org/invidious.git Note that I only own one of those repos. Result: repos ls -la
total 20
drwxr-xr-x 5 gituser gituser 4096 Aug 29 08:29 .
drwxr-xr-x 4 gituser gituser 4096 Aug 28 16:16 ..
drwxr-xr-x 7 gituser gituser 4096 Aug 29 08:29 invidious.git
drwxr-xr-x 7 gituser gituser 4096 Aug 29 08:29 rgit.git
drwxr-xr-x 7 gituser gituser 4096 Aug 29 08:29 slabs-from-wood.git docker host as user holly gid and uid 1000 in docker group docker run --mount type=bind,source=/mnt/data/rgit/repos,target=/git \
--user 1001:1001 -p 3333:8000 \
-it ghcr.io/w4/rgit:main Result:
Thinking more on this, what user does your docker run under? |
Can you paste here the exact command you entered to bring up the container?
Can you also you paste the output of ls -l /srv/repos? docker exec -it 30af494feac7 /bin/bash && ls -l /git Thinking more on this, what user does your docker run under?
i'll try to change a few commands and test little bit and share with feedbacks for sure... |
moved server from 6666 to 3001, it's working... buuut no repos ( |
hold on, i know what't wrong. it's just my stupidity. let me put that config into repo. |
nope, still not showing... maybe config isn't correct? [core]
repositoryformatversion = 0
filemode = true
bare = true
[gitweb]
owner = "Sokhibjon Orzikulov" |
I see that the server is working, however your directory structure is incorrect. The listing of I have also noticed that repos without commits do not show up, so simply If you remove the contents of Your directory structure should look like
|
Those directories are owned by What do the logs say when scanning? |
thank you all very much for support! ❤️ i guess we need to cover all those on readme docker guide imo. |
Not yet seen that something like docker run --mount type=bind,source=/srv/repos,target=/git \
--user 1000:101 \
-it -d --restart always -p 3001:8000 ghcr.io/w4/rgit:main is a known good example. Neither seen that ( removed
shows the error that triggered this merge request ( #10 ). Now waiting for a docker user to be explicit about it. |
Awesome work, thanks guys! |
On Tue, Aug 29, 2023 at 04:39:36AM -0700, Sokhibjon Orzikulov wrote:
i guess we need to cover all those on readme docker guide imo.
In my opinion should the above 'imo' in all caps.
Luckly we care more about source code then opinions.
Sokhibjon, please try to add to the README.md what you were missing.
Groeten
Geert Stappers
--
Silence is hard to parse
|
I'm sorry for late response. The current readme seems fine, tried it again and works fine. Closing the issue. |
This is a fix for #10