Skip to content

Instantly share code, notes, and snippets.

@lindowx
lindowx / SimpleCorsMiddleware.php
Last active April 20, 2018 05:20
A simple CORS middleware for Lumen framework
<?php
/*
* A simple CORS middleware for Lumen framework
*
* lindowx
*/
namespace App\Http\Middleware;
use Closure;
@lindowx
lindowx / phabricator-chinese-translation.json
Last active June 7, 2019 03:50
Phabricator中文翻译JSON-汉化
{
"Config": "\u914d\u7f6e",
"Maniphest": "\u4efb\u52a1&Bug",
"Tasks": "\u4efb\u52a1&Bug",
"Phriction": "\u6587\u6863\u5e93",
"Projects": "\u9879\u76ee",
"Joined": "\u53c2\u4e0e\u4e2d",
"Translations": "\u7ffb\u8bd1",
"Countdown": "\u5012\u8ba1\u65f6",
"Files": "\u6587\u4ef6\u7ba1\u7406",
@lindowx
lindowx / certbot_on_centos-rhel-5.sh
Last active December 20, 2022 16:15
Setup CertBot on CentOS/RHEL 5
#!/bin/sh
#Create working directory
CERTBOT_DIR=/opt/modules/src/certbot
mkdir $CERTBOT_DIR/src -p
cd $CERTBOT_DIR/src
#install openssl to working dir.
wget --no-check-certificate https://www.openssl.org/source/openssl-1.0.1t.tar.gz
tar xvzf openssl-1.0.1t.tar.gz && cd openssl-1.0.1t