打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
云Ubuntu 20.04 系统下 erpnext v13 安装部署(图文并茂按步骤基本成功)

本文基于京东云,Ubuntu 20.04 ,系统安装

本文全程使用"FinalShell SSH"   "Noepad++" 工具

一.使用ssh登录京东云 (不会自行度娘)

  二.更换阿里源(防止因网络问题出错)

       1.安全起见先备份原始源

  • sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup

       2.修改文件(位置:/etc/apt/sources.list)

       2.打开sources.list文件,删除里面全部内容,

          替换以下源

    1. deb http://mirrors.aliyun.com/ubuntu/ focal main restricted
    2. deb http://mirrors.aliyun.com/ubuntu/ focal-updates main restricted
    3. deb http://mirrors.aliyun.com/ubuntu/ focal universe
    4. deb http://mirrors.aliyun.com/ubuntu/ focal-updates universe
    5. deb http://mirrors.aliyun.com/ubuntu/ focal multiverse
    6. deb http://mirrors.aliyun.com/ubuntu/ focal-updates multiverse
    7. deb http://mirrors.aliyun.com/ubuntu/ focal-backports main restricted universe multiverse
    8. deb http://mirrors.aliyun.com/ubuntu/ focal-security main restricted
    9. deb http://mirrors.aliyun.com/ubuntu/ focal-security universe
    10. deb http://mirrors.aliyun.com/ubuntu/ focal-security multiverse

          修改后

       保存上传服务器

三,更新Ubuntu系统

     1.检查Ubuntu系统是否有更新

  • sudo apt update

     2.升级Ubuntu系统

  • sudo apt upgrade

     3.确认升级(输入Y)

        更新速度看服务器的带宽

 四.更新系统并且重启系统

  • apt update && apt upgrade -y && shutdown -r now

五.安装curl

  • sudo apt-get install curl

 六.用curl下载node.js

  • curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -

七.安装erpnext v13 依赖

  • apt install -y nodejs mariadb-server-10.3 redis-server python3-pip nginx python3-testresources

 八.修改数据库文件  (位置 /etc/mysql/my.cnf)  最后面添加以下内容

    1. [mysqld]
    2. character-set-client-handshake = FALSE
    3. character-set-server = utf8mb4
    4. collation-server = utf8mb4_unicode_ci
    5. [mysql]
    6. default-character-set = utf8mb4

九.重启数据库

  • service mysql restart

十.数据库安全配置(记住自己的数据库密码)

  • mysql_secure_installation
  1. Enter current password for root (enter for none): 
  2. #这里直接回车
  3. Set root password? [Y/n] Y
  4. New password:                 输入自己的数据库密码
  5. Re-enter new password:   输入自己的数据库密码
  6. Remove anonymous users? [Y/n] Y
  7. Disallow root login remotely? [Y/n] n
  8. Remove test database and access to it? [Y/n] Y
  9. Reload privilege tables now? [Y/n] Y

 十一.数据库授权

  1. mysql -u root -p
  2.  输入上面设置的密码并执行
    1. USE mysql;
    2. UPDATE user SET plugin=' ' WHERE user ='root';
    3. FLUSH PRIVILEGES;
    4. exit;

十二.创建用户

  1. 创建用户(zhzy更换自己用户)
    adduser zhzy
  2. 输入密码

  3. 下面直接回车键(最后输入Y)

  4. 授权(zhzy更换自己用户)

    usermod -aG sudo zhzy

十三.切换刚创建的用户并进入根目录(zhzy更换自己用户)

  1. su zhzy
  2. cd ~

十四.当前用户 pip 更换国内源

  1. 创建目录
    mkdir ~/.pip
  2. 打开文件
    vim ~/.pip/pip.conf
  3. 粘贴以下内容(注意粘贴内容完整性)
    1. [global]
    2. timeout = 120
    3. index-url = https://mirrors.aliyun.com/pypi/simple/
    4. [install]
    5. trusted-host=mirrors.aliyun.com

  4. 保存退出(先按一下键盘esc,接着shift+z+z) 

十五.更改 root 用户的 pip 国内源(输入自己用户密码) 

  1. sudo mkdir /root/.pip

  2. sudo cp ~/.pip/pip.conf /root/.pip
  3. 更改 npm 的源为国内的淘宝
    sudo apt install npm
    npm config set registry https://registry.npm.taobao.org

十六.安装yarn

  1. sudo npm install -g yarn

  2. 配置 Yarn 为国内的源
    yarn config set registry https://registry.npm.taobao.org

  3. 查看安装版本

    node -v && npm -v && python3 -V && pip3 -V && yarn -v

十七. 安装bench(输入下面两条命令)

  1. pip3 install frappe-bench

  2. sudo pip3 install frappe-bench

 十八.重启系统

  • sudo reboot

十九.安装git

  • sudo apt install git

二十. 使用bench命令安装frappe框架  (此步骤时间长.耐心等待)一直无响应.输入rm -r hrf 删除之前           生成的目录  重新运行

  1. 切换用户(更换自己创建的用户名).并且在根目录
    su zhzy
    cd ~

  2.  安装命令(hrf 更换自己目录名)
    bench init --frappe-branch version-13 hrf --frappe-path=https://gitee.com/phipsoft/frappe

     下面出现错误(别急)

    系统会接着 下载

    出现以下就差不多了

    安装完成

  3.  (重复此步骤.直到安装成功) 如果未出现上图所示或一直无响应. 断开重新连接shh.回到第一步骤输入
    rm -r hrf

    输入2次y

二十一. 进入bench目录(hrf更换自己目录名)

  • cd hrf

二十二.创建站点(指定数据库创建站点)

  1. bench new-site erpnext --verbose --db-name erpnext --db-host 127.0.0.1 --db-port 3306 --mariadb-root-username root --mariadb-root-password xxxx --admin-password admin --force

    bench new-site erpnext                       更换你的站点名

    --db-name erpnext                               更换自己数据库名

    --mariadb-root-password xxxx            更换上面数据库的密码

     --admin-password admin                    更换自己站点管理密码

  2. 安装完成{出现错误(检查问题)重复第一步骤}

 二十三.下载Erpnext

  • bench get-app --branch version-13 https://gitee.com/qinyanwan/erpnext
  • 下载完成

 二十四.安装erpnext

  • bench install-app erpnext

 二十五.supervisorctl管理.nginx作网页反向代理服务器(zhzy更换自己创建的用户名和用户密码)

  • sudo bench setup production zhzy
  • 输入Y 
  •  完成

 二十六.浏览器输入网站IP(恭喜你ERP架设完成)

以下为后续优化.

欢迎加入ERPNext中文QQ群641514022(大神聚集为你排忧解难)

一 .安装余老师汉化APP

  1. 下载
    bench get-app --branch master https://gitee.com/yuzelin/erpnext_chinese

  2. 安装
    bench install-app erpnext_chinese

本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
【热】打开小程序,算一算2024你的财运
ubuntu16.04将python2改为python3并安装pip3最新版
Ubuntu 16.04 一系列软件安装命令,包括QQ、搜狗、Chrome、vlc、网易云音乐安装方法
win10利用WSL2安装docker的2种方式
如何优雅地在 Linux 上运行 QQ、微信?
新手安装Ubuntu 16.04 操作系统
不用装双系统,直接在 Windows 上体验 Linux
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服