1、安装python
python下载地址
https://www.python.org/downloads/
选好版本下载
bash
wget https://www.python.org/ftp/python/3.11.9/Python-3.11.9.tar.xz
安装编译工具
bash
sudo dnf groupinstall "Development Tools"
安装依赖包
bash
dnf install bzip2-devel ncurses-devel gdbm-devel tk-devel libuuid-devel libnsl readline-devel
dnf install sqlite-devel libffi-devel
dnf install openssl-devel
编译
bash
./configure
安装
bash
make && make install
创建软连接
bash
ln -s /usr/local/bin/python3.11 /usr/local/bin/python
2、安装Ansible
使用国内源
bash
pip3 config set global.index-url https://pypi.mirrors.ustc.edu.cn/simple
安装
bash
pip3 install --upgrade pip
pip3 install setuptools-rust
pip3 install ansible
windows作为客户端使用winrm安装如下模块
bash
pip3 install "pywinrm>=0.3.0"
3、安装git
bash
dnf install git
4、安装mysql 数据库
bash
wget https://repo.mysql.com//mysql84-community-release-el8-1.noarch.rpm
安装源
bash
dnf install mysql84-community-release-el8-1.noarch.rpm
禁用默认mysql模块
bash
dnf module disable mysql
安装mysql
bash
dnf install mysql-community-server
启动mysql
bash
systemctl start mysqld
systemctl enable mysqld
修改root密码
bash
grep 'temporary password' /var/log/mysqld.log
bash
mysql -uroot -p
ALTER USER 'root'@'localhost' IDENTIFIED BY 'MyNewPass4!';
5、安装Semaphore
bash
wget https://github.com/semaphoreui/semaphore/releases/download/v2.10.22/semaphore_2.10.22_linux_amd64.rpm
bash
dnf install semaphore_2.10.22_linux_amd64.rpm
创建一个软件目录
bash
mkdir /opt/semaphore
进入软件目录,生成配置文件
启动
bash
nohup semaphore server --config /opt/semaphore/config.json > /dev/null 2>&1 &
输入url访问
新建项目
项目创建完成后、进入控制台