#
基础环境支撑
yum -y install wget screen curl python
安装包下载及配置
echo "下载oneinstack安装包,包含源码,国内外均可"
wget http://mirrors.linuxeye.com/oneinstack-full.tar.gz
echo "解压安装包"
tar xzf oneinstack-full.tar.gz
echo "更改当前目录"
cd oneinstack
echo "如果需要修改目录(安装、数据存储、Nginx日志),"
echo "请修改options.conf文件"
开始安装
安装预备
echo "如果网路出现中断,可以执行命令"
echo "`screen -R oneinstack`"
echo "重新连接安装窗口"
screen -S oneinstack
./install.sh
安装选项
- Please input SSH port(Default: 22):
- 请输入ssh端口(默认22): 22
- Do you want to enable iptables?
- 是否开启 iptables防火墙: y
- Do you want to install Web server?
- 是否安装web服务: y
- Please select Nginx server
- 请选择Nginx 服务器类型: Install Nginx
- Please select Apache server:
- 请选择Apache 服务器类型: Do not install
- Please select Tomcat server:
- 请选择Tomcat 服务器类型: Install Tomcat-8
- Please select JDK version:
- 请选择JDK版本: Install JDK-1.8
- Do you want to install Database?
- 是否安装数据库服务: y
- Please select a version of the Database:
- 请选择数据库版本: Install MySQL-5.7
- Please input the root password of database
- 请输入数据库root用户密码: root
- Please choose installation of the database:
- 请选择数据库安装方式: Install database from binary package
- 该方式为二进制方式(另一个为源码编译方式), 更快.
- Do you want to install PHP?
- 是否安装PHP服务: y
- Please select a version of the PHP:
- 请选择PHP版本: Install php-7.0
- 依据实际开发需求,现行 5.6 or 7
- Do you want to install opcode cache of the PHP?
- 是否安装PHP代码缓存组件: y
- 使用该组件可以提升PHP服务性能
- Please select a opcode cache of the PHP:
- 请选择PHP代码缓存组件: Install Zend OPcache
- 如果选择ZOP将不会安装ZendGuardLoader, 如需使用请换其他组件
- Do you want to install ionCube?
- 是否安装PHP代码加密组件: y
- 网站中有加解密需求才安装.
- Do you want to install ImageMagick or GraphicsMagick?
- 是否安装IM或GM图像处理组件: y
- Install GraphicsMagick
- Do you want to install Pure-FTPd?
- 是否安装Pure-FTPd服务: y
- Do you want to install phpMyAdmin?
- 是否安装phpMyAdmin: y
- Do you want to install redis?
- 是否安装redis服务: y
- Do you want to install memcached?
- 是否安装memcached服务: y
- Do you want to install HHVM?
- 是否安装HHVM虚拟机: y
- 建议 n
安装ing…
预计 安装用时超过半小时
安装结束
记录好安装信息后重启服务器查看安装结果
添加虚拟主机
echo "更改当前目录"
cd /~/oneinstack
./vhost.sh
- Please choose to use environment:
- 请选择主机类型:
- Use php
- Use java
- Use hhvm
- 请选择主机类型:
添加php主机
添加java主机
- Do you want to setup SSL under Nginx?
- 是否安装ssl支持 y
- Please input domain(example: www.example.com)
- 请输入主机域名
- Please input the directory for the domain
- 请输入该域名主机根目录
- Do you want to add more domain name
- 是否启用多域名支持: n
Do you want to redirect all HTTP requests to HTTPS
- 是否自动重定向http到https: y
输入签名证书信息
- Country Name 国别名
- State or Province Name 省份
- Locality Name 城市名
- Organization Name 公司全称
- Organizational Unit Name 部门名称
- Do you want to add hotlink protection?
- 是否启用防盗链
———-
以下与本文无关
http://www.ttlsa.com/nginx/nginx-tcp-proxy/
http://www.centoscn.com/image-text/install/2015/0319/4918.html
http://caucho.com/products/resin/getting-started-with-resin
http://caucho.com/products/resin/download