Skip to content

Instantly share code, notes, and snippets.

#前言 感謝小飛機掏出一台主機借我玩

ACCTON SAF4121I

原本想說裝個archlinux應該不難

殊不知這台只有console port 並沒有vga

#Trace Config

downlad nginx and compile with ldap_auth module

  • downlad nginx : wget http://nginx.org/download/nginx-1.9.9.tar.gz
  • download ldap_auth_module : git clone https://github.com/kvspb/nginx-auth-ldap
  • decompression : tar -zxvf nginx-1.9.9.tar.gz
  • move to nginx : cd nginx-1.9.9
  • configure :
./configure /etc/nginx --conf-path=/etc/nginx/nginx.conf \
--sbin-path=/usr/bin/nginx \
--pid-path=/run/nginx.pid \
--lock-path=/run/lock/nginx.lock \
  1. vim /etc/systemd/system/gitlab.service

  2. [gitlab.service]

[Unit]
Description=gitlab containers
Requires=docker.service
After=docker.service
[Service]
Restart=always
global m
def short(data,start,end,time,n,cost,array):
global m
if start > end:
s = end
e = start
else:
s = start
e = end
if len(data[s])>0:
@CliffLin
CliffLin / wireless
Created July 17, 2015 10:55
/etc/config/wireless
config wifi-device radio0
option type mac80211
option channel 11
option hwmode 11g
option path 'platform/ar934x_wmac'
option htmode HT20
# REMOVE THIS LINE TO ENABLE WIFI:
option disabled 0
config wifi-iface
ovs-vsctl add-br ovs-br
ovs-vsctl add-port ovs-br eth0.1
ovs-vsctl add-port ovs-br eth0.2
ovs-vsctl add-port ovs-br eth0.3
ovs-vsctl add-port ovs-br eth0.5
ovs-vsctl add-port ovs-br br-wifi0
@CliffLin
CliffLin / network
Last active August 29, 2015 14:24
/etc/config/network
config interface 'loopback'
option ifname 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'
config interface 'lan1'
option ifname 'eth0.1'
option proto 'static'