时间:2020-03-06来源:电脑系统城作者:电脑系统城
conf目录下:主要copy的文件时httpd.conf,主要是配置apache可以访问到git并通过账号密码控制
git-team.htpasswd: 这个文件提供了初始化的用户,主要包含两个,分别是usertest/admin
[附件:httpd.conf]
[附件:git-team.htpasswd]
FROM centos:centos7
MAINTAINER Imagine Lin<linzhiguo@afcat.com.cn>
ENV SSH_PASSWORD=P@ssw0rd
COPY git-team.htpasswd /opt/http_git/gitpasswd/git-team.htpasswd
RUN yum -y install git wget vim net net-tools grep awk sed exec httpd-2.4.6 httpd-devel-2.4.6 httpd-tools-2.4.6 && \
mkdir -p /opt/http_git/ud.git && \
cd /opt/http_git/ud.git && \
git init --bare && \
chown -R apache:apache /opt/http_git && \
chown apache:apache /opt/http_git/gitpasswd/git-team.htpasswd && \
chmod 640 /opt/http_git/gitpasswd/git-team.htpasswd
COPY conf /etc/httpd/conf
EXPOSE 80
CMD ["/usr/sbin/httpd","-D","FOREGROUND"]
#uyw-git: 是镜像名称。1.0是tag名称
docker build -t uyw-git:1.0 .
docker run -d -it -p 10000:80 --name uyw-git -v dataVolumeGit1:/opt/http_git/gitpasswd uyw-git:1.0
2026-06-09
win10系统以太网连接图标不见了怎么办 Win10 / Win11 找不到以太网通用解决方法2024-04-11
台式机电脑如何连接外接显示器2024-04-11
小新系列打印机手机配置网络的方法教程一、40系列之后机型 X(250、240s、240、230s) X1 carbon(20BT/20BS) YOGA 11e T(550、540p、450s、450、440s、440p、440、431s) W(550s、540、541) L(450、440、550) E(550、55...
2024-04-11
ThinkPad蓝牙鼠标如何配对解答步骤41U5008鼠标驱动官网地址: https://support.lenovo.com/en_US/downloads/detail.page?&LegacyDocID=MIGR-67201 第一种方式是比较传统的:使...
2024-04-11