# adapted from http://spottedhyena.co.uk/centos-67-ipsecl2tp-vpn-client-unifi-usg-l2tp-server/
yum -y install epel # different on amazon linux
sudo yum -y install xl2tpd openswan
systemctl start ipsec.service
service ipsec start
# 'myserver.com' is just to help identify. these are all imported into /etc/ipsec.conf.
vim /etc/ipsec.d/myserver.com.conf # see next...
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | # | |
| # /etc/sysctl.conf - Configuration file for setting system variables | |
| # See /etc/sysctl.d/ for additonal system variables | |
| # See sysctl.conf (5) for information. | |
| # | |
| #kernel.domainname = example.com | |
| # Uncomment the following to stop low-level messages on console | |
| #kernel.printk = 3 4 1 3 | 
原文:Linux中国
认识 71 个 AWS 云服务的术语 ! 通过了解 AWS 世界中使用的术语开始你的 AWS 云服务使用生涯 !
-- Shrikant Lavhate
本文导航
      This file has been truncated, but you can view the full file.
    
    
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | { | |
| "acm": { | |
| "AddTagsToCertificate": [ | |
| "aws acm add-tags-to-certificate --certificate-arn arn:aws:acm:us-east-1:123456789012:certificate/12345678-1234-1234-1234-123456789012 --tags Key=Admin,Value=Alice Key=Purpose,Value=Website " | |
| ], | |
| "DeleteCertificate": [ | |
| "aws acm delete-certificate --certificate-arn arn:aws:acm:us-east-1:123456789012:certificate/12345678-1234-1234-1234-123456789012 " | |
| ], | |
| "DescribeCertificate": [ | |
| "aws acm describe-certificate --certificate-arn arn:aws:acm:us-east-1:123456789012:certificate/12345678-1234-1234-1234-123456789012 " | 
- Kubernetes instance calculator.
 - Allocatable memory and CPU in Kubernetes Nodes
 - Allocatable memory and CPU resources on GKE.
 - AWS EKS AMI reserved CPU and reserved memory.
 - AKS resource reservations.
 - Official docs https://kubernetes.io/docs/tasks/administer-cluster/reserve-compute-resources/)
 - Enabling prefix assignment in EKS and VPC CNI.
 
加入代码审计小密圈: https://wx.xiaomiquan.com/mweb/views/joingroup/join_group.html?group_id=2212251881
代码审计小密圈从去年11月成立至今已有近半年时间,一直没有把我们的宗旨和规则明文写出来,一是我比较懒事儿也比较多,二是我发现大家都是善良的小纯白,并没有谁是揣着恶意来到这里,所以这个事儿也不是特别急。但一直没有成文的规定总不是办法,有的新人进来后,四顾何茫茫,不领要旨,可能会觉得钱花的不值。
办这个圈子,脑子里有几句话,我一直奉为圭臬,在这里说一下。
关于bloom filter算法: http://www.cnblogs.com/heaad/archive/2011/01/02/1924195.html
参考项目:
- https://github.com/jettify/aioredis_bloom 基于asyncio的异步实现
 - https://github.com/seomoz/pyreBloom 基于C语言的实现
 
作用:海量数据的去重,时间、空间复杂度为常量:O(K)。
原理:借助redis,维护一个BitSet(位集合)。通过bloom filter算法判断一个数据是否重复。
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | import hashlib as hasher | |
| import datetime as date | |
| # Define what a Snakecoin block is | |
| class Block: | |
| def __init__(self, index, timestamp, data, previous_hash): | |
| self.index = index | |
| self.timestamp = timestamp | |
| self.data = data | |
| self.previous_hash = previous_hash | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | location ~* ^/remote-files/(http[s]*://)(.*?)/(.*) { | |
| # Do not allow people to mess with this location directly | |
| # Only internal redirects are allowed | |
| internal; | |
| # nginx has to be able to resolve the remote URLs | |
| resolver 8.8.8.8; | |
| # Location-specific logging | |
| #access_log /usr/local/etc/nginx/logs/internal_redirect.access.log main; | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | sudo npm update npm -g | |
| sudo npm cache clean -f | |
| sudo npm install -g n | |
| sudo n stable | 
NewerOlder