現在靜態檔基本上都給 Nginx 噴,這個 http server 號稱小又快
看 Source code 是使用 PHP + Swoole 來實作的,剛 release 1.0.0 版,先記錄一下,有空再來玩玩看~
small-static-http:使用 PHP Swoole 寫的靜態 HTTP server
基本上這套預設的路徑、Log、User 都是 Follow Apache、Nginx,上手還算蠻方便的~
small-static-http 安裝、Log 路徑位置
- 安裝:docker pull sebk69/small-static-http
- 系統預設參數
- memory_limit : Max allowed memory size
- timezone : timezone for logs
- user_id : user id for www-data user
- /var/www : directory to serve
- /etc/small-static-http.json : configuration file
新聞可見:small-static-http 1.0.0 released
- small-static-http is a small http server, get reponse very fast by caching all static content in memory (response from localhost < 8ms).
small-static-http 專案位置
- Git Repository:Sébastien Kus / small-static-http · GitLab
- Docker Hub:sebk69/small-static-http - Docker Image