docker svn
生活随笔
收集整理的這篇文章主要介紹了
docker svn
小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.
1 安裝
docker pull paulovsm/svn-server
2 運(yùn)行
docker run --name svn -p 8082:80? -v /home/svn:/home/svn? -d paulovsm/svn-server
3 訪問:
svn:? ??http://xxx:8082/svnadmin
svnadmin:? ?http://xxx:8082/svnadmin
4 進(jìn)入容器
docker exec -it svn bash
5?docker容器中安裝vi命令
apt-get update 命令的作用是:同步 /etc/apt/sources.list 和 /etc/apt/sources.list.d 中列出的源的索引,這樣才能獲取到最新的軟件包。apt-get install vim 修改配置 [root@iZuf6boi8ejfovwda7q1ynZ svn]# docker exec -it svn bash root@d54dc86dc03a:/# cd /var/www/svnadmin/data root@d54dc86dc03a:/var/www/svnadmin/data# vi config.ini [Common] FirstStart=0 BackupFolder=./data/backup/[Translation] Directory=./translations/[Engine:Providers] AuthenticationStatus=basic UserViewProviderType=passwd UserEditProviderType=passwd GroupViewProviderType=svnauthfile GroupEditProviderType=svnauthfile AccessPathViewProviderType=svnauthfile AccessPathEditProviderType=svnauthfile RepositoryViewProviderType=svnclient RepositoryEditProviderType=svnclient[ACLManager] UserRoleAssignmentFile=./data/userroleassignments.ini[Subversion] #SVNAuthFile=/etc/subversion/authz.conf SVNAuthFile=/home/svn/svnconfig/accessfile [Repositories:svnclient] SVNParentPath=/home/svn/data SvnExecutable=/usr/bin/svn SvnAdminExecutable=/usr/bin/svnadmin[Users:passwd] SVNUserFile=/home/svn/svnconfig/passwdfile[Users:digest] SVNUserDigestFile= SVNDigestRealm=SVN Privat 保存,重新運(yùn)行容器
6 提交修改容器
[root@iZuf6boi8ejfovwda7q1ynZ svn]# docker commit -m "svn & svnadmin" -a "svn-svnadmin" d54dc86dc03a sohudo/svn-svnadmin:latest sha256:3c879974b8c17704fdb96965a18649e41e3fc9f36c6867207d494067e06c5e29 [root@iZuf6boi8ejfovwda7q1ynZ svn]# docker images REPOSITORY TAG IMAGE ID CREATED SIZE sohudo/svn-svnadmin latest 3c879974b8c1 20 seconds ago 311.8 MB docker.io/paulovsm/svn-server latest 2d7d81d37ff2 2 years ago 256.4 MB7 運(yùn)行新的容器
[root@iZuf6boi8ejfovwda7q1ynZ svn]# docker run --name svnadmin -p 8088:80 -v /home/svn:/home/svn -d sohudo/svn-svnadmin e48266d60e1da526278d946fdbf24a728ece6d00c3735b031513cd35bf5ccd25 [root@iZuf6boi8ejfovwda7q1ynZ svn]# docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES e48266d60e1d sohudo/svn-svnadmin "./startup.sh" 5 seconds ago Up 4 seconds 0.0.0.0:8088->80/tcp svnadmin d54dc86dc03a paulovsm/svn-server "./startup.sh" 9 days ago Up About an hour 0.0.0.0:8082->80/tcp svn ? ? 進(jìn)入容器 設(shè)置目錄權(quán)限??chmod -R 777 ./svnsvnadmin密碼9EOjBreLZk
8:docker login
[root@iZuf6boi8ejfovwda7q1ynZ ~]# docker login Login with your Docker ID to push and pull images from Docker Hub. If you don't have a Docker ID, head over to https://hub.docker.com to create one. Username: sohudo Password: Login Succeeded9:docker push?
docker push sohudo/svn-svnadmin The push refers to a repository [docker.io/sohudo/svn-svnadmin] 508c08da5368: Pushed 5f70bf18a086: Pushed latest: digest: sha256:dc37a7099d252a368cbc5280180aee04e4d30cfba7870e6ed1fde9da8d34563b size: 9874
總結(jié)
以上是生活随笔為你收集整理的docker svn的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Docker Gogs
- 下一篇: ngrok编译和安装