lnmp.sh 837 B

123456789101112131415161718192021
  1. #!/bin/bash
  2. # Usage: curl -L http://git.io/lnmp.sh | bash
  3. # 建立网站和数据库目录和下载wordpress程序设置目录权限
  4. mkdir -p /data/www/ /data/mysql
  5. cd /data/www
  6. curl https://cn.wordpress.org/latest-zh_CN.tar.gz | tar -zx
  7. chown -R www-data:www-data /data/www/wordpress
  8. # 安装 docker-compose 部署工具,部署lnmp
  9. wget https://raw.githubusercontent.com/hongwenjun/nginx-php/main/lnmp/docker-compose.yml
  10. apt install -y docker-compose
  11. docker-compose up -d
  12. # 配置 wordpress 默认密码
  13. echo -e ":: 登陆网址: http://www.yourname.net/wp-admin 配置wordpress网站信息"
  14. echo -e ":: 数据库名: wordpress \n:: 用户名 : root \n:: 密 码 : WordPress@2021 \n:: db主机 : db "
  15. echo
  16. echo -e ":: 数据库管理: http://www.yourname.net:10086 推荐先修改数据库 root 密码 "