原文:lua resty template && openresty 使用

. 安裝 luarocks install lua resty template . 使用 配置模板頁面位置 有多種方式: a. 直接使用root 目錄 代碼如下: location root html content by lua local template require resty.template template.render view.html , message Hello, W ...

2017-04-04 21:41 0 2739 推薦指數:

查看詳情

openresty 使用lua-resty-shell 執行shell 腳本

lua-resty-shell 是一個很不錯的項目,讓我們可以無阻塞的執行shell命令,之間的通信 是通過socket (一般是unix socket) 環境准備 docker-compose 文件 dockerfile ...

Fri Dec 07 04:50:00 CST 2018 0 1883
OpenResty 擴展庫之(一)——lua-resty-shell 庫

介紹   當您需要執行子進程(或shell命令)時,這是一個打算與OpenResty應用程序一起使用的小型庫。 它類似於os.execute和io.popen,除了它是完全非阻塞的,因此即使對於需要很長時間完成的命令也是安全的。   該庫依賴於您需要在Web服務器(sockproc)上運行 ...

Fri May 05 05:17:00 CST 2017 0 3809
openresty lua-resty-string md5 sha aes random string

安裝 https://github.com/openresty/lua-resty-string 可以看出目錄下多出了這幾個文件:aes.lua md5.lua random.lua sha.lua sha1.lua sha224.lua sha256.lua sha384.lua ...

Tue Sep 17 05:41:00 CST 2019 0 701
openresty 集成lua-resty-mail +smtp2http 擴展靈活的mail 服務

lua-resty-mail 是一個不錯的openresty mail 擴展,我們可以用來進行郵件發送,支持附件功能 smtp2http 是一個smtp 服務,可以將smtp 請求數據轉換為http rest 請求,這個在我們的實際應用 中還是很方便的,比如需要mail 服務,但是我們需要進行 ...

Fri Jan 04 17:10:00 CST 2019 0 684
openresty開發系列24--openrestylua的引入及使用

openresty開發系列24--openrestylua的引入及使用openresty 引入 lua一)openresty中nginx引入lua方式 1)xxx_by_lua --->字符串編寫方式 2) xxx_by_lua_block ---->代碼塊方式 ...

Fri Aug 30 19:52:00 CST 2019 0 1228
openresty + lua 4、openresty kafka

  kafka 官網: https://kafka.apache.org/quickstart   zookeeper 官網:https://zookeeper.apache.org/   kaf ...

Thu Nov 23 01:31:00 CST 2017 0 1234
OpenResty使用lua-zlib的方法

==================================================================1、查看 zlib在centos 中是否存在?rpm -qa | g ...

Wed Dec 31 15:29:00 CST 2014 0 5248
 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM