Apache安装配置
1、安装Apache服务
yum install httpd -y
2、启动Apache服务
service httpd restart
发现警告
启动成功,有警告
vi /etc/httpd/conf/httpd.conf
将ServerName改为如下:
#ServerName www.example.com:80
ServerName localhost:80
启动成功
3、添加index.html
默认发布目录为:/var/www/html,默认发布文件为:index.html
cd /var/www/html
vi index.html
index.html
4、访问服务器
访问服务器成功
MDwiki下载配置
1、下载MDwiki
wget https://github.com/Dynalon/mdwiki/releases/download/0.6.2/mdwiki-0.6.2.zip
unzip mdwiki-0.6.2.zip
将解压后的文件夹移动到/var/www/html下,移动后结构如下:
目录结构
mdwiki-0.6.2目录结构
2、修改index.html
index.html
3、访问服务器
访问服务器
4、点击mdwiki,发现错误
点击wiki查看页面
5、按照错误提示添加文件
index.md
navigation.md
config.json
添加后目录结构
6、刷新页面
正常页面
可能出现问题
1、无法访问服务器
解决:检查防火墙设置
2、无法访问mdwiki
解决:检查文件目录权限