zoukankan      html  css  js  c++  java
  • Linux安装OpenResty api 网关 Orange

    1.安装openresty

    # yum -y install libuuid-devel pcre-devel openssl-devel gcc-c++ wget
    # mkdir /openresty
    # cd /openresty
    # wget https://openresty.org/download/openresty-1.9.15.1.tar.gz
    # tar -zxf openresty-1.9.15.1.tar.gz
    # cd openresty-1.9.15.1
    # ./configure --with-http_stub_status_module --with-http_v2_module --with-http_ssl_module 
    # gmake && gmake install
    # ln -s /usr/local/openresty/nginx/sbin/nginx /usr/sbin/nginx
    # nginx -v
    

    2.创建MySQL数据库并导入数据(脚本在orange/install文件夹下)

    # yum -y install mariadb-server
    # mysql -u root
    # CREATE DATABASE orange CHARACTER SET utf8 COLLATE utf8_general_ci;
    # CREATE USER 'orange'@'%' IDENTIFIED BY 'orange';
    # GRANT ALL PRIVILEGES ON orange.* TO 'orange'@'%';
    # FLUSH PRIVILEGES;
    # 最后一定要执行mysql的数据库导入。
    # mysql -u orange -porange -h 10.0.2.15 orange < orange-v0.6.2.sql
    

    3.安装Orange

    安装之前需要 lor 框架,否则启动有问题。
    # yum install -y git
    # git clone https://github.com/sumory/lor.git
    # cd lor
    # make install
    
    启动并配置 orange 服务
    # service iptables stop
    # chkconfig iptables off
    # git clone https://github.com/sumory/orange.git
    # cd orange
    # vim conf/orange.conf
    # sh start.sh
    
    2743275-2e009409e9d775d4.png
    访问地址: http://IP:9999
    2743275-b87cf50db17bdbf6.png

    Tips:启动不起来查看端口占用情况杀掉其他进程

    # netstat -tunlp |grep 80
    
  • 相关阅读:
    c# 实现鼠标拖拽TreeView节点
    代码生成组合编码
    .net分布式错误,DTC出错问题
    乱七八糟?Ⅱ.哈哈
    用SQL只获取日期的方法
    C#学习之接口
    webservice 上传图片、下载图片
    Python包系列
    多线程多进程模块
    第九章Admin后台系统
  • 原文地址:https://www.cnblogs.com/zhousiwei/p/10625662.html
Copyright © 2011-2022 走看看