elleflorio / svn-docker Goto Github PK
View Code? Open in Web Editor NEWLightweight Docker image to build a container running an SVN server
License: MIT License
Lightweight Docker image to build a container running an SVN server
License: MIT License
Hi, I'm trying out this image, and svnadmin works fine at https://.../svn/svnadmin
however the page at https://.../svn
just shows It works! which I presume is an apache default page. It seems like the DAV module isn't operational, at least interpreting the readme as I do.
I'm running the whole thing in a docker network with an nginx proxy in it as well which redirects to the svn-server image.
I wrote “python scripts” for hooks,but there is not python
and py-pip
package,Could you please put apk add python py-pip
in the dockerfile? Thanks
Where does this docker image store the configuration data? I have done -v <hostpath>:/home/svn
but I think this is only to persist the SVN repositories.
After setting up username and password via
docker exec -t svn-server htpasswd -b /etc/subversion/passwd <username> <password>
If I then recreate the container (e.g. new image version, etc), all configurations appear to have been lost. I can no longer login with user set above.
svn: E175002: Unexpected HTTP status 413 'Request Entity Too Large' on '/svn/private/!svn/txr/7586-69q/Modelagem
To make it easier to configure, I changed the properties of the dev_svn.conf file
AuthUserFile /home/svn/passwd
AuthzSVNAccessFile /home/svn/access
But when I open localhost:port/svn/
I get an error!
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, add.com@phpstudy and inform them of the time the error occurred, and anything you might have done that may have caused the error
I checked the error.log and found errors.
AH01620: Could not open password file: /home/svn/passwd
Because/etc/subversion/passwd
can be accessed normally.
So I compared the files /home/svn/passwd
and /etc/subversion /passwd
All of their users are root:root
After several attempts, I found that I had to set /home/svn/passwd
to user name apache
in order for the settle
Hi, I created a user named 'admin' in iF.SVNAdmin Web page, after that I assign a Access-Path with 'read & write' permission to a exists user (not admin) and 'no permission' to '*', then that user is forbiddened to access the path whith http.
When I tail the /var/log/apache2/error.log, it shows that:
[authz_svn:error] [pid 281] [client 10.0.16.50:50879] Access denied: 'admin' OPTIONS XXXXXX:/
Finally I delete the 'admin' user, it get fine again.
The svn admin interface packaged does support (with a little fixing -- see issues in their repository) LDAP; including groups and access to repository paths, so all in all pretty powerful.
In order for the svn checkout to work through the apache server created here, you'd need to update the configuration. We did that in our configuration (not possible to create a pull request though) but feel free to contact me incase you have any troubles. It was a very straight forward fix with a little bit of googling.
Hi Luca,
I sometimes get dyslexic and reverse the order of things, so i had to double and triple check before i opened this issue, but your documentation, Dockerfile, etc are referencing port 3960. However, the correct port for SVN is 3690.
$ grep -E '3(69|96)0' /etc/services
svn 3690/tcp # Subversion
svn 3690/udp # Subversion
bess 3960/tcp # Bess Peer Assessment
bess 3960/udp # Bess Peer Assessment
I'm not sure if you meant to obscure the service by writing this backwards or if you suffer from dyslexia occasionally too :-) but this has caused me much confusion when I couldn't get SVN to work connecting to your container :-)
Would you mind if i submit a PR to correct this or is this way for a reason ? If the latter, could you please make a note in your docs so as not to trip other people up like I have been :-)
Hi, many thanks for your repo, it works like a charm! However, I've recently tried to change the port mapping to, say 80:81 or whatever? It doesn't work for me at all and I'm probably missing something here.
Ciao,
I have created a container based on your image one year ago. Yesterday the container take 16 GByte on my Docker server.
I deleted and recreated container and after this it take 50 MByte. Today, after few days, it take 190 MByte.
Are you aware of this issue and can you helpme to fix?
Many thanks in advance.
Marco
The svn access control file should be relocated into a volume otherwise access configurations won't be persistent. The file / folder in question is /etc/subversion/subversion-access-control, although this is configureable in the admin interface under backend settings.
Hi,
I've set up your docker container using docker-compose on my Synology diskstation.
When I run it and want to access the svnadmin I get the following error message:
Error: Could not copy configuration file template. Require write permission (777) to "data" folder and all containing files.
#0 /opt/svnadmin/index.php(20): include_once()
#1 {main}
folder and file privileges should be good. Here's my compose file:
and here's the directory structure showing the privileges
When starting the container I also found out, that the empty passwd file was missing. It's inside your docker file but it was not created or copied to the configured svn_config dir (./svn_config:/etc/subversion)
I had to manually add it as well as the subversion-access-control file
If you need any further details I'm glad to help!
Hi, I pull the image, and try to connect to 80 port but failured. And the site (https://medium.com/@elle.florio/the-svn-dockerization-84032e11d88d#.bafh3otmh) I cant open.
run command is :
docker run -d --name svn-server -p 8091:80 -p 3960:3960 elleflorio/svn-server
And then I try to access 8091 : http://localhost:8091/svn, browser return with message: ERR_CONNECTION_REFUSED
Hi,
I have the following problem:
fresh container, no volume only ports mapped
created user with docker exec
if no repository exists http /svn displays correctly with no repositories.
as soon as I create a repo either via web svnadmin or via docker exec svnadmin create there is nothing displayed under the /svn url anymore just the error "connection reset"
in the apache error log I found these entries:
[Sun Jul 14 20:24:26.274401 2019] [core:notice] [pid 263] AH00051: child pid 3236 exit signal Segmentation fault (11), possible coredump in /var/www
even chown'ing the files in /home/svn as apache:apache and chmod'ing them 777 did not help.
any ideas?
I followed the instructions and I can see a running server and can access it via svn and web (i.e. http://serverip/svn). A valid user is set via htpasswd and the credentials work well.
I used a fresh docker volume, mounted to /home/svn.
As soon as I create a repository via "docker exec -it svn-server svnadmin create /home/svn/testrepo" I won't get the repository page anymore, but the network connection is reset. I can't access the repository via svn:// eigther. When I use "docker exec -it svn-server ls -al /home/svn/testrepo" I get a valid listing for the newly created repository structure. I can see it in the volume directly as well.
If I delete the testrepo, the empty overview page at http:/serverip/svn becomes available again.
I could verify this behaviour on 2 different servers and also on a brandnew ubuntu 18.04 installation with docker and a rightful user that is part of the docker group.
Did I miss any access rights settings or do I have to alter any web_dav.conf settings to enable apache to access the repository properly?
Can anyone else confirm this behaviour?
Thank you very much in advance.
Hi,
im running this config with docker-compose:
subversion:
image: elleflorio/svn-server
container_name: subversion
ports:
- "81:80"
- "3690:3690"
i´m adding a user:
docker exec -t subversion htpasswd -b /etc/subversion/passwd admin admin
in brower i can see everything fine:
http://192.168.222.10:81/svn/
Collection of Repositories
Powered by Apache Subversion version 1.12.2 (r1863366).
then i create a repository:
docker exec -t subversion svnadmin create Test
if i try to access the repo in brower:
http://192.168.222.10:81/svn/Test
i´m getting errror that the page is not aviable...
in apache log i can see:
==> /var/log/apache2/access.log <==
192.168.222.175 - admin [23/Nov/2019:13:06:38 +0000] "GET /svn/ HTTP/1.1" 200 254 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:70.0) Gecko/20100101 Firefox/70.0"
192.168.222.175 - admin [23/Nov/2019:13:06:39 +0000] "GET /svn/ HTTP/1.1" 200 254 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:70.0) Gecko/20100101 Firefox/70.0"
==> /var/log/apache2/error.log <==
[Sat Nov 23 13:06:52.403545 2019] [core:notice] [pid 253] AH00051: child pid 270 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:06:52.403635 2019] [core:notice] [pid 253] AH00051: child pid 271 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:06:52.403678 2019] [core:notice] [pid 253] AH00051: child pid 272 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:06:52.403714 2019] [core:notice] [pid 253] AH00051: child pid 273 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:06:52.403807 2019] [core:notice] [pid 253] AH00051: child pid 274 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:06:52.403848 2019] [core:notice] [pid 253] AH00051: child pid 275 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:06:53.406506 2019] [core:notice] [pid 253] AH00051: child pid 291 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:06:54.411574 2019] [core:notice] [pid 253] AH00051: child pid 292 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:06:54.411820 2019] [core:notice] [pid 253] AH00051: child pid 293 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:06:55.421070 2019] [core:notice] [pid 253] AH00051: child pid 294 exit signal Segmentation fault (11), possible coredump in /var/www
in /var/www is no coredump....
with Tortoise SVN the same:
==> /var/log/apache2/access.log <==
127.0.0.1 - - [23/Nov/2019:13:06:56 +0000] "OPTIONS * HTTP/1.0" 200 - "-" "Apache/2.4.41 (Unix) SVN/1.12.2 PHP/7.2.24 (internal dummy connection)"
192.168.222.175 - - [23/Nov/2019:13:09:31 +0000] "OPTIONS /svn HTTP/1.1" 401 459 "-" "SVN/1.13.0 (x64-microsoft-windows) serf/1.3.9 TortoiseSVN-1.13.1.28686"
192.168.222.175 - admin [23/Nov/2019:13:09:31 +0000] "OPTIONS /svn HTTP/1.1" 500 606 "-" "SVN/1.13.0 (x64-microsoft-windows) serf/1.3.9 TortoiseSVN-1.13.1.28686"
192.168.222.175 - - [23/Nov/2019:13:09:31 +0000] "OPTIONS / HTTP/1.1" 200 - "-" "SVN/1.13.0 (x64-microsoft-windows) serf/1.3.9 TortoiseSVN-1.13.1.28686"
==> /var/log/apache2/error.log <==
[Sat Nov 23 13:09:31.582530 2019] [core:notice] [pid 253] AH00051: child pid 296 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:09:31.582606 2019] [core:notice] [pid 253] AH00051: child pid 297 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:09:31.582637 2019] [core:notice] [pid 253] AH00051: child pid 298 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:09:31.582664 2019] [core:notice] [pid 253] AH00051: child pid 299 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:09:31.582693 2019] [core:notice] [pid 253] AH00051: child pid 301 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:09:31.882931 2019] [dav:error] [pid 304] [client 192.168.222.175:50649] Could not fetch resource information. [-2, #0]
[Sat Nov 23 13:09:31.882973 2019] [dav:error] [pid 304] [client 192.168.222.175:50649] The URI does not contain the name of a repository. [405, #190001]
[Sat Nov 23 13:09:32.585564 2019] [core:notice] [pid 253] AH00051: child pid 300 exit signal Segmentation fault (11), possible coredump in /var/www
[Sat Nov 23 13:09:32.585668 2019] [core:notice] [pid 253] AH00051: child pid 302 exit signal Segmentation fault (11), possible coredump in /var/www
what wrong?
Hi.
It would be good to be able to disable the webDAV interface if we only want the subversion server to respond to svn:// requests.
Right now, you can just not map 80/443, but apache still commits ~100M of memory, which is not being used in any way if the user isn't using WebDAV.
Ideally, this should be linked to either an environment variable so that it can be set at the CLI (or in a docker-compose.yml
), or an argument.
Thanks!
hi
i meet a problem in latest image.
the svn version of latest image is 1.9.7,
Transmitting file data .svnsync: E160000: SHA1 of reps '97086 3 52814 4194940 02
cd8fba5619943735e5d3b70983e13d c067b31e7165338f23fc62b51b4d5f84446b9f25 97086-22
wy/_6' and '-1 0 52814 4194940 02cd8fba5619943735e5d3b70983e13d c067b31e7165338f
23fc62b51b4d5f84446b9f25 97086-22wy/_6' matches (c067b31e7165338f23fc62b51b4d5f8
4446b9f25) but contents differ
it is a bug of svn version.
https://issues.apache.org/jira/projects/SVN/issues/SVN-4722?filter=allissues
how could i upgrade svn version?
or use the v1.9.9 svn version to package a new image?
thank you!
When I try to run the latest Docker image (image ID d703d1921c8a
), it doesn't work:
$ docker pull elleflorio/svn-server
Using default tag: latest
latest: Pulling from elleflorio/svn-server
Digest: sha256:6b04c01a8c8f9fcf72f0ef2a0de133ee4b82eefae7475ab1f87d740b35f8a2ee
Status: Image is up to date for elleflorio/svn-server:latest
$ docker run elleflorio/svn-server:latest
[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] 01-resolver-resolv: applying...
[fix-attrs.d] 01-resolver-resolv: exited 0.
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 30-resolver: executing...
[cont-init.d] 30-resolver: exited 0.
[cont-init.d] 40-resolver: executing...
[cont-init.d] 40-resolver: exited 0.
[cont-init.d] done.
[services.d] starting services
./run: exec: line 5: /usr/sbin/apachectl: not found
[services.d] done.
./run: exec: line 5: /usr/sbin/apachectl: not found
./run: exec: line 5: /usr/sbin/apachectl: not found
./run: exec: line 5: /usr/sbin/apachectl: not found
./run: exec: line 5: /usr/sbin/apachectl: not found
./run: exec: line 5: /usr/sbin/apachectl: not found
^C[cont-finish.d] executing container finish scripts...
I compared the files in the Docker image to those in a previous version that does work, and it appears that the file /usr/sbin/apachectl
is indeed missing compared to the previous version.
I found an issue that looks related: webdevops/Dockerfile#250
The solution appears to be installing the apache2-ctl
package.
modify httpd config:/etc/apache2/httpd.conf
add
ServerName: localhost:80
Hello, in the use of your subversion image, report permission issues, is it my configuration error, the following is my screenshot,and attached to my docker-compose.yml
Enclosure.zip
Hello, I have a question about the permission configuration of the new account. After I add the user account and configure the permissions, the permissions will not be updated in real time. Instead, the permission configuration will take effect by restarting the svn service. I use http Protocol way to use svn, I want to ask if I have not set up the configuration?
Hi,
I would like to change the timezone, and I tried it per volume and envireoment variable, but nothing worked for me:
docker run (.....)
--volume /etc/localtime:/etc/localtime:ro
-e "TZ=Europe/Berlin"
The "date" is always one hour behind my host.
Greetings
Steffen
hi, elleFlorio,
I run the container and finished the iF.SVNAdmin first login and click the Save Configuration button, it tells me auto create a admin account ,user name and password all is "admin", but i can't login. it prompt me Wrong user/password combination. Is there any way I can reset the
admin password? thanks!
svnadmin - no have power for configure svn repositories (for protocol svn://
).
svn checkout
repository via http
- it's ok (server requested login/password)svn checkout
via svn:/
protocol - it's anytime available for any repository (no secure)Error in viewing user or group details,LDAP is already configured.
Error: Call to a member function getSections() on null
#0 /opt/svnadmin/include/ifcorelib/IF_SVNAuthFileC.class.php(723): IF_SVNAuthFileC->repositories()
#1 /opt/svnadmin/classes/providers/AuthFileGroupAndPathsProvider.class.php(294): IF_SVNAuthFileC->permissionsOfUser('august')
#2 /opt/svnadmin/userview.php(114): svnadmin\providers\AuthFileGroupAndPathProvider->getPathsOfUser(Object(svnadmin\core\entities\User))
#3 {main}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.