Linux+XAMPP+eolinker开源版v3.2.4

本文涉及的产品
云数据库 RDS MySQL Serverless,0.5-2RCU 50GB
云数据库 RDS MySQL Serverless,价值2615元额度,1个月
简介: eolinker是一个由国人开源的接口管理系统(AMS),特性及介绍详见开源中国-eolinker首页.搭建步骤参考:eolinker开源指南系统环境:CentOS Linux release 7.

eolinker是一个由国人开源的接口管理系统(AMS),特性及介绍详见开源中国-eolinker首页.

搭建步骤参考:eolinker开源指南

系统环境:CentOS Linux release 7.3.1611 x86_64 GNU/Linux

工具准备

  • eolinker开源版(码云):git clone https://gitee.com/eoLinker-API-Management/eoLinker-OS_3.X-CHN.git

    img_d89a9e9c2cefca6d09bacc3d1c54860c.png

  • xampp
    选择XAMPP for Linux(7.2.1 / PHP 7.2.1)

    img_95709a8f7fe044a5d1bf3872038bb1a1.png

    下载完成后是一个.run文件。

安装XAMPP

  1. 将下载完成的xampp和eolinker.zip上传到服务器;
  2. 给xampp安装包赋予可执行的权限;
chmod 777 xampp-linux-x64-7.2.1-0-installer.run
  1. 运行./chmod 777 xampp-linux-x64-7.2.1-0-installer.run 进行安装操作,安装过程遇到确认的地方都选择Y;
    img_45f82b64ce6d8c8bf4ee66dbca15a03d.png
    image.png

配置lampp全局可见:cp /opt/lampp/lampp /usr/bin/lampp
配置xampp-mysql全局可见:sudo ln -s /opt/lampp/bin/mysql /usr/bin

  1. 启动XAMPP
#启动
lampp start 或 /opt/lampp/lampp satrt
#关闭
lampp stop
#重启
lampp restart
#卸载
rm -rf /opt/lampp/
img_df07c01f708a2133bfca5d6ac581b548.png
  1. 访问测试
  • 在浏览器中输入服务器IP地址后回车,可以查看XAMPP首页;


    img_dbee5ddb4b4cf587cad06be257fe47e2.png
    dashboard
  • 服务器新建php文件:vi /opt/lampp/htdocs/phpinfo.php,输入以下代码后,:wq保存;
<?
phpinfo();
?>

浏览器地址中输入:服务器IP/phpinfo.php,正常情况下,会显示以下页面:


img_6150122b4f0f26b7a1fee0d1b3c5924c.png

在页面上搜索,可以发现,php默认已经安装并启用了mbstring,curl,pdo拓展,eolinker依赖这些模块;

  1. 设置mysql允许外部连接
    xampp安装的mysql root用户默认是没有密码的,首先进入mysql:
#这里没有密码,直接回车
[root@rethink] /opt/lampp/bin/mysql -u root -p
Enter password: 
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 3
Server version: 10.1.30-MariaDB Source distribution

Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> set password =password('your passwd');
Query OK, 0 rows affected (0.00 sec)

#设置完成后,还需要给root用户开放权限:
MariaDB [(none)]> GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'your passwd' WITH GRANT OPTION;
Query OK, 0 rows affected (0.00 sec)

MariaDB [(none)]> flush privileges;
Query OK, 0 rows affected (0.00 sec)

MariaDB [(none)]> \q;
Bye

还需要修改phpmyadmin的配置文件:vi /opt/lampp/phpmyadmin/config.inc.php

img_310c7eb32e3b2430098b7c6b96baa256.png

将$cfg['Servers'][$i]['password'] = ''; 设置成刚才修改的root密码,保存后关闭,重启xampp: lampp restart

  1. 访问phpMyAdmin
    在浏览器中输入:服务器IP/phpmyadmin/, 可能会出现Access forbidden,按照提示信息修改配置文件httpd-xampp.conf:
    vi /opt/lampp/etc/extra/httpd-xampp.conf
    img_0866e7148065313d1de82db3cf5cb720.png

在第21行加上一句Require all granted,然后重启xammp服务:lampp restart, 就可以实现远程访问了。

phpMyAdmin页面如下:


img_9b07a54b6ef2923db16f4e64700324da.png

部署eolinker

  1. /opt/lampp/htdocs/目录下新建目录:mkdir eolinker,将eolinker压缩包移动到此目录下,然后解压:unzip eolinker_os_3.2.4.zip
  2. 项目目录需要具有完全的读写权限(777),用于写入配置文件。
    chmod -R 777 /opt/lampp/htdocs/eolinker/
  3. 新建一个数据库,用于存储项目数据。可以通过phpMyAdmin新建,也可以通过命令行新建;


    img_f9b8a3cf1f7f35b2e77da17226c35691.png

    下面是通过命令行创建:

$ /opt/lampp/bin/mysql -u root -p
Enter password: 
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 128
Server version: 10.1.30-MariaDB Source distribution

Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> create database eolinker_os;
Query OK, 1 row affected (0.00 sec)

MariaDB [(none)]> show databases;
+--------------------+
| Database           |
+--------------------+
| eolinker_os        |
| information_schema |
| mysql              |
| performance_schema |
| phpmyadmin         |
| test               |
+--------------------+
6 rows in set (0.00 sec)

MariaDB [(none)]> \q;
Bye
  1. 浏览器访问项目:服务器IP/eolinker/,出现以下引导页面:


    img_4ea97ce631283a55aae1ca384c848e30.png

根据指引页面提示,输入相应数据库信息并通过环境监测后,即可安装成功。


img_3e4651ceea7f9f1a91dfdb1e4f851d6a.png
img_49e9a8381280358c70964bf9c52fb8ab.png
img_376207ac78d6edbf58e092d08254c09f.png
img_e16a1f6f3b8b11bfa253d35e4156fa31.png
相关实践学习
基于CentOS快速搭建LAMP环境
本教程介绍如何搭建LAMP环境,其中LAMP分别代表Linux、Apache、MySQL和PHP。
全面了解阿里云能为你做什么
阿里云在全球各地部署高效节能的绿色数据中心,利用清洁计算为万物互联的新世界提供源源不断的能源动力,目前开服的区域包括中国(华北、华东、华南、香港)、新加坡、美国(美东、美西)、欧洲、中东、澳大利亚、日本。目前阿里云的产品涵盖弹性计算、数据库、存储与CDN、分析与搜索、云通信、网络、管理与监控、应用服务、互联网中间件、移动服务、视频服务等。通过本课程,来了解阿里云能够为你的业务带来哪些帮助 &nbsp; &nbsp; 相关的阿里云产品:云服务器ECS 云服务器 ECS(Elastic Compute Service)是一种弹性可伸缩的计算服务,助您降低 IT 成本,提升运维效率,使您更专注于核心业务创新。产品详情: https://www.aliyun.com/product/ecs
相关文章
|
2月前
|
存储 监控 Linux
linux搭建EwoMail开源邮件服务器软件
linux搭建EwoMail开源邮件服务器软件
30 0
|
4月前
|
安全 Unix Linux
【Linux入门指南:掌握开源操作系统的基础知识】(四)
【Linux入门指南:掌握开源操作系统的基础知识】
|
4月前
|
Linux
【Linux入门指南:掌握开源操作系统的基础知识】(三)
【Linux入门指南:掌握开源操作系统的基础知识】
|
4月前
|
存储 Linux 虚拟化
Linux和开源存储
Linux和开源存储
Linux和开源存储
|
8天前
|
存储 搜索推荐 Linux
|
9天前
|
Unix 大数据 Linux
Linux系统简介与开源精神
Linux系统简介与开源精神
28 3
|
9天前
|
安全 Linux Shell
Linux:探索开源之魅与编程之道
Linux:探索开源之魅与编程之道
21 4
|
9天前
|
安全 Unix Linux
Linux:开源之美与代码之韵
Linux:开源之美与代码之韵
20 1