工作网站建设中布线费用账务处理,专门做包包的网站,襄州区住房和城乡建设局网站,网络营销企业推广策划目录 零、前提一、下载离线包二、安装三、访问四、开机自启 零、前提 1.前提是已经安装了docker和docker-compose
一、下载离线包 1. csdn资源#xff1a;harbor-offline-installer-v2.10.0.tgz 2. 百度云盘#xff08;提取码#xff1a;ap3t#xff09;#xff1a;harbo… 目录 零、前提一、下载离线包二、安装三、访问四、开机自启 零、前提 1.前提是已经安装了docker和docker-compose
一、下载离线包 1. csdn资源harbor-offline-installer-v2.10.0.tgz 2. 百度云盘提取码ap3tharbor-offline-installer-v2.10.0.tgz 3. github官方地址harbor-offline-installer-v2.10.0.tgz 4. github下载速度太慢建议翻墙
二、安装 1. 创建目录/opt/harbor
# 创建目录
sudo mkdir /opt/harbor2. 将离线包上传到目录/opt/harbor 3. 在该目录下解压离线包
sudo tar xf harbor-offline-installer-v2.10.0.tgz4. 复制一个harbor.yml
sudo scp -r harbor.yml.tmpl harbor.yml5. 编辑文件harbor.yml
sudo vim harbor.yml6. 修改内容
# The IP address or hostname to access admin UI and registry service.
# ip地址或主机名去访问管理界面和注册服务
# DO NOT use localhost or 127.0.0.1, because Harbor needs to be accessed by external clients.
# 不要使用localhost和127.0.0.1因为harbor需要被外部客户端访问改成主机ip吧
hostname: 172.18.208.85# http related config
http:# port for http, default is 80. If https enabled, this port will redirect to https port# http的端口默认是80。这里改的是18080port: 18080# https related config
# 注释https配置关闭https
#https:# https port for harbor, default is 443# port: 443# The path of cert and key files for nginx#certificate: /your/certificate/path#private_key: /your/private/key/path 7. 保存
:wq8.运行./install.sh安装脚本
sudo ./install.sh9.查看容器信息
sudo docker ps -a三、访问 1.访问地址http://172.18.208.85:18080 2.ip为配置里的ip端口为配置里的端口 4.账号为admin密码为Harbor12345(配置里的harbor_admin_password: Harbor12345
四、开机自启 1.进入目录/opt/harbor/harbor
cd /opt/harbor/harbor2.编辑脚本
sudo vim start.sh3.输入内容
cd /opt/harbor/harbor
sudo docker-compose stop docker-compose start4.保存退出
:wq5.赋予执行权限
sudo chmod x /opt/harbor/harbor/start.sh6.编辑rc.local
sudo vim /etc/rc.d/rc.local7.将命令文件绝对路径添加到文件最后
touch /var/lock/subsys/local
/opt/harbor/harbor/start.sh8.给rc.local赋予权限
sudo chmod x /etc/rc.d/rc.local