Working with Nginx

All command have to run at nginx.exe folder. An example of nginx.conf See demo server configuration in nginx.conf Set auto-startup with WinSW.exe Windows 可以通过手动修改注册表设置启动项,感觉有些麻烦,还是找个工具。找到工具 WinSW ,它可以将任何应用包裹并作为一个 Windows 服务管理。 WinSW 作为一个全局工具使用: 下载 WinSW.exe 或 WinSW.zip 。 新建 myapp.xml 运行 winsw install myapp.xml [options] 安装服务。 运行 winsw start myapp.xml 开启服务。 运行 winsw status myapp.xml 检查服务是否启动和运行。 拷贝WinSW.exe到Nginx文件夹 新建WinSW.xml文件,并加入以上配置 管理员运行WinSW.exe将服务加入services.msc中

Letsencrypt & Certbot

Normally, we can use Let’s Encrypt to request a https certificate. This certificate will have 90 days available before expiry. First, we need to have a Certbot tool in our system. Please check the link below to require a script to setup your certbot environment. https://certbot.eff.org/instructions?ws=nginx&os=windows Download the installation package for your current system. Once …

OpenSSL on Windows

OpenSSL can do SELF certify https certificate. Setup OpenSSL with Environment: 1, Download openssl from https://slproweb.com/products/Win32OpenSSL.html. Install openssl into system. 2, Have to set /bin into system path. Make sure that ‘openssl’ command can be run in terminal. 3, Use ‘openssl version’ in cmd to check the version. Generate Certificate: 1, Locate into a folder, …