暗能星系

    • 登录
    • 搜索

    RATH服务化部署

    软件部署及教程
    1
    1
    5
    正在加载更多帖子
    • 从旧到新
    • 从新到旧
    • 最多赞同
    回复
    • 在新帖中回复
    登录后回复
    此主题已被删除。只有拥有主题管理权限的用户可以查看。
    • Z
      zhangfanglin 最后由 编辑

      本地:

      下载代码

      git clone https://github.com/Kanaries/Rath.git && cd Rath
      

      在本地设置RATH客户端:

      yarn install
      yarn workspace rath-client build
      

      启动RATH客户端:

      yarn workspace rath-client start
      

      如果默认端口(localhost:3000)不可用,RATH将自动提示一个新的端口建议。输入y并按下Enter键启动RATH。

      docker

      dockerfile

      FROM ubuntu:20.04
      USER root
      RUN apt-get update && apt-get install supervisor nginx vim net-tools  curl gnupg2 -y
      
      RUN curl -s https://deb.nodesource.com/setup_16.x | bash
      RUN apt-get update && apt-get install nodejs -y
      
      
      RUN  apt-get remove cmdtest
      RUN  apt-get remove yarn
      
      RUN  curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg |  apt-key add -
      RUN  echo "deb https://dl.yarnpkg.com/debian/ stable main" |  tee /etc/apt/sources.list.d/yarn.list
      RUN  apt-get update && apt-get install yarn -y
      
      ADD Rath /var/www/html/Rath
      WORKDIR /var/www/html/Rath
      RUN node -v
      RUN yarn install
      RUN yarn workspace rath-client build
      #RUN yarn workspace rath-client start
      
      ADD supervisord.conf /etc/supervisor/conf.d/
      ENTRYPOINT supervisord -c /etc/supervisor/supervisord.conf
                                                                
      

      supervisord配置

      [supervisord]
      nodaemon=true
      logfile=/dev/null
      logfile_maxbytes=0
      pidfile=/run/supervisord.pid
      
      
      [program:rath]
      command=yarn workspace rath-client start
      stdout_logfile=/var/log/stdout
      stdout_logfile_maxbytes=0
      stderr_logfile=/var/log/stderr
      stderr_logfile_maxbytes=0
      autorestart=false
      startretries=0
      
      
      1 条回复 最后回复 回复 引用 0
      • First post
        Last post
      Powered by 暗能星系