ZDHsys
Platform for automatic installation of operating system based on golang and saltstack
The main implementation of binding MAC address, independent installation of the operating system, change the host name, IP address
The project is still being updated...
Installation
Installing golang(linux)
-
Download address:https://golang.google.cn/dl/
-
package :go1.12.6.linux-amd64.tar.gz
-
uncompress
# tar -C /usr/local/ -zxf go1.11.2.linux-amd64.tar.gz
-
Setting environment variables
# echo export PATH=$PATH:/usr/local/go/bin/ >> /etc/profile # source /etc/profile # go env\
Installing beego
# yum install -y git
# go get github.com/astaxie/beego
# go get github.com/beego/bee
# go get github.com/astaxie/beego/orm
# echo export PATH=$PATH:/root/go/bin >> /etc/profile
# source /etc/profile
# bee
Installing other packages
- Json parsing library
- mysql driver
- call python for golang
# go get github.com/bitly/go-simplejson
# go get github.com/go-sql-driver/mysql
# yum install -y python-devel
# go get github.com/sbinet/go-python
# mkdir -p /root/go/src/golang.org/x
# cd /root/go/src/golang.org/x
# git clone https://github.com/golang/crypto.git
Installing mysql
-
download:mysql
-
create a remote login user
mysql> grant all on *.* to "root"@"192.168.100.111" identified by "WWW.1.com"; mysql> flush privileges;
-
create database
mysql> create database test charset=utf8;
Installing cobbler
- slightly