A Pen by wangxiaolei on CodePen.
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
| <div class="images"> | |
| <img class="image" src="https://pic2.zhimg.com/v2-6aa9abffb2d52b8afe9af4cb4ba09db5.jpg"/> | |
| <img class="image" src="https://pic2.zhimg.com/v2-6aa9abffb2d52b8afe9af4cb4ba09db5.jpg"/> | |
| <img class="image" src="https://pic3.zhimg.com/v2-f5b2c99bc559e4d10b1ca1250bc1311a.jpg"/> | |
| <img class="image" src="https://pic4.zhimg.com/v2-24c14572f54488a8c1fd7af38f7f8007.jpg"/> | |
| <img class="image" src="https://pic4.zhimg.com/v2-24c14572f54488a8c1fd7af38f7f8007.jpg"/> | |
| <img class="image" src="https://pic3.zhimg.com/v2-961a979bdead64c3f827c324879eff9a.jpg"/> | |
| <img class="image" src="https://pic3.zhimg.com/v2-961a979bdead64c3f827c324879eff9a.jpg"/> | |
| <img class="image" src="https://pic2.zhimg.com/v2-01a4709e70b13f9a59183e8029a23e41.jpg"/> | |
| <img class="image" src="https://pic2.zhimg.com/v2-01a4709e70b13f9a59183e8029a23e41.jpg"/> |
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
| class override_func_params(object): | |
| def __init__(self, *args, **kwargs): | |
| self.override_args = args | |
| self.override_kwargs = kwargs | |
| def __call__(self, func): | |
| def wrapper(*args, **kwargs): | |
| if kwargs: | |
| kwargs.update(self.override_kwargs) | |
| if args: |
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
| # Path to Oh My Fish install. | |
| set -gx OMF_PATH "$HOME/.local/share/omf" | |
| # Load oh-my-fish configuration. | |
| source $OMF_PATH/init.fish | |
| # Plugins | |
| set FISH_PLUGINS git | |
| # set GOPATH |
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
| /data/logs/nginx/*.log { | |
| su root root | |
| daily | |
| missingok | |
| compress | |
| delaycompress | |
| rotate 10 | |
| sharedscripts | |
| postrotate | |
| [ -f /data/run/nginx.pid ] && kill -USR1 `cat /data/run/nginx.pid` |
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
| [supervisord] | |
| logfile = /data/logs/supervisor/supervisord.log | |
| logfile_maxbytes = 50MB | |
| logfile_backups=10 | |
| loglevel = info | |
| pidfile = /data/run/supervisord.pid | |
| nodaemon = false | |
| minfds = 1024 | |
| minprocs = 200 | |
| umask = 022 |
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
| input { | |
| beats { | |
| port => "5043" | |
| } | |
| } | |
| filter { | |
| if [type] == "broker" { | |
| grok { | |
| match => { |
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
| ################### Filebeat Configuration Example ######################### | |
| ############################# Filebeat ###################################### | |
| filebeat: | |
| # List of prospectors to fetch data. | |
| prospectors: | |
| # Each - is a prospector. Below are the prospector specific configurations | |
| # General filebeat configuration options | |
| # |
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
| # -*- coding: utf8 -*- | |
| import random | |
| import string | |
| def rand_str(length): | |
| return ''.join(random.choice(string.ascii_uppercase + string.digits) for _ in range(length)) |