服务管理
systemctl list-unit-files <span class="hljs-comment"># 列出所有配置文件</span>
systemctl list-unit-files --<span class="hljs-built_in">type</span>=service <span class="hljs-comment"># 列出指定类型的配置文件</span>
systemctl list-unit-files --<span class="hljs-built_in">type</span>=service | grep enabled <span class="hljs-comment"># 查看开机启动的服务</span>
systemctl list-units --<span class="hljs-built_in">type</span>=service <span class="hljs-comment"># 列出所有正在运行的、类型为 service 的 Unit</span>
systemctl start nginx <span class="hljs-comment"># 启动服务</span>
systemctl status nginx <span class="hljs-comment"># 查看服务状态</span>
systemctl <span class="hljs-built_in">enable</span> nginx <span class="hljs-comment"># 开机启动服务</span>
systemctl <span class="hljs-built_in">disable</span> nginx <span class="hljs-comment"># 开机不启动服务</span>
Flarum插件/主题
安装插件/主题时, 切记下面两项:
- 记得切换到网站目录下:
cd /vat/www/flarum
;
- 记得使用安装Flarum的用户:
sudo -u yaro composer require xxx
(sudo = switch user do);
使用方法:
composer require flarum-lang/chinese-simplified
php flarum cache:clear
升级/卸载: 将安装命令中的 require 替换为 update 或 remove