当前位置: 首页 > news >正文

flex做的网站怎么重置wordpress

flex做的网站,怎么重置wordpress,快手流量推广软件免费,软文写作模板准备环境 准备两台纯净的服务器进行#xff0c;在实验之前我们关闭防火墙和selinux systemctl stop firewalld #关闭防火墙 setenforce 0 #临时关闭selinux hosts解析(两台服务器都要去做) [rootansible-server ~]# vim /etc/hosts 10.31.162.24 ansible-ser…准备环境 准备两台纯净的服务器进行在实验之前我们关闭防火墙和selinux systemctl stop firewalld #关闭防火墙 setenforce 0 #临时关闭selinux hosts解析(两台服务器都要去做) [rootansible-server ~]# vim /etc/hosts 10.31.162.24 ansible-server 10.31.162.25 ansible-web安装ansible 10.31.162.24 安装控制节点1. 配置EPEL网络yum源[rootansible-server ~]# yum install -y epel*2. 安装ansible[rootansible-server ~]# yum install -y ansible3.查看版本[rootansiable-server ~]# ansible --version4.查看配置文件 [rootansible-server ~]# rpm -qc ansible ---1.主配置文件/etc/ansible/ansible.cfg #主要设置一些ansible初始化的信息比如日志存放路径、模块、插件等配置信息 ---2.主机清单文件:默认位置/etc/ansible/hosts安装nginx # 配置nginx源 [rootansible-server ~]# vim /etc/yum.repos.d/nginx.repo [nginx-stable] namenginx stable repo baseurlhttp://nginx.org/packages/centos/$releasever/$basearch/ gpgcheck0 enabled1 gpgkeyhttps://nginx.org/keys/nginx_signing.key module_hotfixestrue # 下载nginx [rootansible-server ~]# yum install -y nginx [rootansible-server ~]# systemctl start nginx [rootansible-server ~]# systemctl enable nginx上传压缩包 将下载好的jdk、tomcat、jspgou上传到server机器上 # 也可以直接官网下载 apache-tomcat-9.0.83.tar.gz jdk-8u321-linux-x64.tar.gz jspgouV6.1-ROOT.zip# jspgou包是gz的包需要解压重新压缩才可以用只能用tar包 [rootansible-server ~]# yum -y install unzip [rootansible-server ~]# unzip jspgouV6.1-ROOT.zip [rootansible-server ~]# tar zcvf jspgou.tar.gz DB ROOT [rootansible-server ~]# ls DB ROOT [rootansible-server ~]# tar zcvf jspgouv6.1.tar.gz DB ROOT jspgouv6.1.tar.gz添加主机 # 添加主机清单 [rootansible-server ~]# vim /etc/ansible/hosts [jspgou] ansible-web# 其他语法 1.添加主机或者主机组 [rootansible-server ~]# vim /etc/ansible/hosts #在最后追加被管理端的机器 ansible-web1 #单独指定主机可以使用主机名称或IP地址 2.添加主机组 [webservers] #使用[]标签指定主机组 ----标签自定义 192.168.10.11 #如果未解析添加ip ansible-web2 #解析添加主机名 3.组可以包含其他组 [webservers1] #组一 ansible-web1 [webservers2] #组二 ansible-web2 [weball:children] #caildren-照写 #weball包括两个子组 webservers1 #组一 webservers2 #组二 4.为一个组指定变量组内每个主机都可以使用该变量 [weball:vars] #设置变量,vars--照写 ansible_ssh_port22 ansible_ssh_userroot ansible_ssh_private_key_file/root/.ssh/id_rsa #ansible_ssh_pass1 #也可以定义密码如果没有互传秘钥可以使用密码。配置ssh密钥 配置ssh公钥认证控制节点需要发送ssh公钥给所有非被控制节点 [rootansible-server ~]# ssh-keygen [rootansible-server ~]# ssh-copy-id -i 10.31.126.25 #所有机器配置剧本 # 在vars目录里配置file.yml配置文件 [rootansible-server ~]# vim /etc/ansible/vars/file.yml src_gou_path: /root/jspgouv6.1.tar.gz src_jdk_path: /root/jdk-8u321-linux-x64.tar.gz src_tomcat_path: /root/apache-tomcat-9.0.83.tar.gz dest_gou_path: /root dest_jdk_path: /root dest_tomcat_path: /root#配置安装MySQL脚本 [rootansible-server ~]# vim /etc/ansible/jsp.sh #!/bin/bash PASS_WORDQianfeng123 #配置源 cat /etc/yum.repos.d/mysql.repo EOF [mysql] namemysql baseurlhttps://mirrors.tuna.tsinghua.edu.cn/mysql/yum/mysql-5.7-community-el7-x86_64/ gpgcheck0 enabled1 gpgkeyhttps://mirrors.ustc.edu.cn/mysql-repo/RPM-GPG-KEY-mysql EOF #下载mysql yum repolist enabled | grep mysql yum -y install mysql-community-server /dev/null #启动 systemctl start mysqld systemctl enable mysqld #获取密码 TEMP_PASSWORD$(sudo grep temporary password /var/log/mysqld.log | awk {print $NF}) #修改密码 mysql -u root -p${TEMP_PASSWORD} --connect-expired-password EOF ALTER USER rootlocalhost IDENTIFIED BY $PASS_WORD; GRANT ALL PRIVILEGES ON *.* TO rootlocalhost WITH GRANT OPTION; FLUSH PRIVILEGES; EOF #重启mysql systemctl restart mysqld#赋予jsp.sh权限 [rootansible-server ~]# cd /etc/ansible/ [rootansible-server ansible]# chmod ox jsp.sh# 在ansible目录里配置jspgou.yml配置文件 [rootansible-server ~]# vim /etc/ansible/jspgou.yml - hosts: jspgouuser: rootbecome: yesvars_files:- /etc/ansible/vars/file.ymltasks:- name: configure jdk1copy: src{{ src_jdk_path }} dest{{ dest_jdk_path }}- name: unzip jdkunarchive: src{{ dest_jdk_path }}/jdk-8u321-linux-x64.tar.gz dest/usr/local/ copyno- name: rename javashell: mv /usr/local/jdk1.8.0_321 /usr/local/java- name: configure jdk envirement1shell: echo JAVA_HOME/usr/local/java /etc/profile- name: configure jdk envirement2shell: echo PATH$JAVA_HOME/bin:$PATH /etc/profile- name: copy tomcatcopy: src{{ src_tomcat_path }} dest{{ dest_tomcat_path }}- name: unzip tomcatunarchive: src{{ dest_tomcat_path }}/apache-tomcat-9.0.83.tar.gz dest/usr/local/ copyno- name: rename tomcatshell: mv /usr/local/apache-tomcat-9.0.83 /usr/local/tomcat- name: rm -rf webappsshell: rm -rf /usr/local/tomcat/webapps/*- name: add /etc/profileshell: sed -i 2i source /etc/profile /usr/local/tomcat/bin/startup.sh- name: add /etc/profile to shutdown.shshell: sed -i 2i source /etc/profile /usr/local/tomcat/bin/shutdown.sh- name: copy jspgoucopy: src{{ src_gou_path }} dest{{ dest_gou_path }}- name: unzip jspgouunarchive: src{{ dest_gou_path }}/jspgouv6.1.tar.gz dest/usr/local/tomcat/webapps copyno- name: Modify MySQL user initial passwordscript: /etc/ansible/jsp.sh removes/etc/passwd- name: enter MySQLshell: mysql -uroot -pQianfeng123 -e create database jspgou default charsetutf8;- name: edit mysqldshell: sed -i s/jdbc.password/jdbc.passwordQianfeng123/ /usr/local/tomcat/webapps/ROOT/WEB-INF/config/jdbc.properties- name: append mysqlshell: echo max_allowed_packet 64m /etc/my.cnf- name: append mysql1shell: echo sql_modeSTRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUB /etc/my.cnf- name: append mysql2shell: echo explicit_defaults_for_timestamp1 /etc/my.cnf- name: restart mysqld1shell: systemctl restart mysqld- name: Import datashell: mysql -uroot -pQianfeng123 -D jspgou /usr/local/tomcat/webapps/DB/jspgou.sql- name: restart mysql11shell: systemctl restart mysqldnotify: start jspgouhandlers:- name: start jspgoushell: nohup /usr/local/tomcat/bin/startup.sh 配置nginx代理 # 备份原有配置文件 [rootansible-server ~]# cp default.conf default.conf.bak # 添加jspgou.conf配置文件 [rootansible-server ~]# vim /etc/nginx/conf.d/jspgou.conf server {listen 80;server_name localhost;location / {proxy_pass http://10.31.162.25:8080;proxy_set_header Host $host:$server_port;proxy_set_header X-Real-IP $remote_addr;proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;}} # 重启nginx [rootansible-server ~]# systemctl restart nginx测试 直接访问代理服务器即可 看到该界面我们的操作就成功了
http://www.dnsts.com.cn/news/38619.html

相关文章:

  • 做任务推广网站网站建设实训周记
  • h5个人网站代码网站建设v杏信zhousi69
  • 网站标题tdk佛山营销网站开发怎么选
  • wordpress多站点功能tvc广告片制作公司
  • 建设模板类网站WordPress七牛防盗链
  • 谷歌网站的设计原则做301重定向会影响网站权重吗
  • 市场网站建设广州企业vi设计公司
  • 网站开发 学习步骤vs2017 asp网站开发
  • 购物商城网站开发实验报告今标 网站建设
  • 汕头网站建站公司实时seo排名点击软件
  • 个人网站可以做企业宣传上海公共服务平台官网
  • 孝义网站开发婚庆策划公司加盟
  • 网站 流程优化房产网签合同
  • 天津百度整站优化服务搭建网站案例精粹
  • 如何在百度建立自己的网站网片排焊机
  • 桂林北站是高铁站吗Wordpress付费置顶
  • 金融公司网站免费模板网站怎么推广出去比较好
  • 做cms网站宿迁公司做网站
  • wordpress中文网站做网站去哪里可以找高清的图片
  • 做调查问卷用的网站或软件厦门做网站seo
  • 网站底部的备案号凡客诚品电话
  • 手机网站表单页面制作公司网站服务器优化
  • 网站前端免费ppt模板下载爱ppt
  • asp.net获取网站虚拟目录怎么创建游戏软件
  • 网站建设案例咨询长沙微信网站
  • 兰州网站制作联系方式搜索引擎优化seo什么意思
  • 上海网站建设哪家比较好网站长期建设 运营计划
  • dz网站后台单位门户网站建设
  • 管理网站建设哪家公司好网站建设手机站
  • 品牌网站建设哪好wordpress怎么破解版