一挠唆、后端服務
1婚脱、kubectl cli客戶端
2、helm3 工具
3重付、mongodb mongodb-linux-x86_64-rhel70-4.4.12
4顷级、gitlab客戶端
5、Linux操作系統(tǒng)
2确垫、前端服務
1弓颈、nginx用于部署前端服務
三帽芽、安裝過程
3.1、helm工具安裝翔冀,下載地址:https://github.com/helm/helm/releases/tag/v3.6.3
3.2 安裝kubectl
curl -LO https://dl.k8s.io/release/v1.24.0/bin/linux/amd64/kubectl
mv kubectl /usr/local/bin
chmod +x /usr/local/bin/kubectl
3.3 安裝mongodb及初始化數(shù)據(jù)
wget https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-rhel70-4.4.12.tgz
mv mongodb-linux-x86_64-rhel70-4.4.12 ../mongodb
cd ../mongodb/
mkdir -p ./data
nohup ./bin/mongod --dbpath ./data &
mondb
use oms ###非常重要导街,需要先切換,然后再創(chuàng)建用戶
db.createUser({
user: "oms",
pwd: 'oms',
roles: [ { role: "userAdminAnyDatabase", db: "admin" } ],
mechanisms : ["SCRAM-SHA-1"]
});
執(zhí)行三張基礎數(shù)據(jù)表:
access.sql 基礎權限數(shù)據(jù)控制
dept.sql 部門基礎數(shù)據(jù)表
serviceType 服務類型基礎表
3.4 安裝nginx
rm -rf /etc/yum.repos.d/epel.repo
cat <<EOF> /etc/yum.repos.d/CentOS-Base.repo
# CentOS-Base.repo
#
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror to pick mirrors that are updated to and
# geographically close to the client. You should use this for CentOS updates
# unless you are manually picking other mirrors.
#
# If the mirrorlist= does not work for you, as a fall back you can try the
# remarked out baseurl= line instead.
#
#
[base]
name=CentOS-$releasever - Base - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos/$releasever/os/$basearch/
http://mirrors.aliyuncs.com/centos/$releasever/os/$basearch/
http://mirrors.cloud.aliyuncs.com/centos/$releasever/os/$basearch/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7
#released updates
[updates]
name=CentOS-$releasever - Updates - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos/$releasever/updates/$basearch/
http://mirrors.aliyuncs.com/centos/$releasever/updates/$basearch/
http://mirrors.cloud.aliyuncs.com/centos/$releasever/updates/$basearch/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7
#additional packages that may be useful
[extras]
name=CentOS-$releasever - Extras - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos/$releasever/extras/$basearch/
http://mirrors.aliyuncs.com/centos/$releasever/extras/$basearch/
http://mirrors.cloud.aliyuncs.com/centos/$releasever/extras/$basearch/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7
#additional packages that extend functionality of existing packages
[centosplus]
name=CentOS-$releasever - Plus - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos/$releasever/centosplus/$basearch/
http://mirrors.aliyuncs.com/centos/$releasever/centosplus/$basearch/
http://mirrors.cloud.aliyuncs.com/centos/$releasever/centosplus/$basearch/
gpgcheck=1
enabled=0
gpgkey=http://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7
#contrib - packages by Centos Users
[contrib]
name=CentOS-$releasever - Contrib - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos/$releasever/contrib/$basearch/
http://mirrors.aliyuncs.com/centos/$releasever/contrib/$basearch/
http://mirrors.cloud.aliyuncs.com/centos/$releasever/contrib/$basearch/
gpgcheck=1
enabled=0
gpgkey=http://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7
EOF
wget http://nginx.org/download/nginx-1.20.2.tar.gz
tar -zxvf nginx-1.20.2.tar.gz
yum -y install pcre pcre-devel
yum -y install openssl openssl-devel
yum -y install zlib zlib-devel
./configure --prefix=/usr/local/nginx --with-http_ssl_module
make && make install
cd /usr/local/nginx/sbin
./nginx ##啟動服務
3.5 安裝gitlab客戶端
3.6 安裝npm and cnpm
npm install -g cnpm --registry=https://registry.npm.taobao.org