This file contains 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
//var screenshot = require('./../screenshot'); | |
describe('Test Login page', function() { | |
beforeEach(function() { | |
// doing something here | |
}); | |
var width = 1600; | |
var height = 2400; | |
browser.driver.manage().window().setSize(width, height); |
This file contains 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
const InvitationHelper = require('../InvitationHelpers'); | |
self.customCreate = (data, fn) => { | |
return findUser() | |
.then(InvitationHelpers.checkParams) | |
.then(InvitationHelpers.checkIsInSP) | |
.then(InvitationHelpers.checkIsInvited) | |
.then(InvitationHelpers.createInvitation) | |
.then(InvitationHelpers.queueEmail) |
This file contains 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
8.2.3. HTTP log format | |
---------------------- | |
The HTTP format is the most complete and the best suited for HTTP proxies. It | |
is enabled by when "option httplog" is specified in the frontend. It provides | |
the same level of information as the TCP format with additional features which | |
are specific to the HTTP protocol. Just like the TCP format, the log is usually | |
emitted at the end of the session, unless "option logasap" is specified, which | |
generally only makes sense for download sites. A session which matches the | |
"monitor" rules will never logged. It is also possible not to log sessions for |
This file contains 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 apt-get install -y build-essential zlib1g-dev libpcre3 libpcre3-dev unzip | |
NPS_VERSION=1.12.34.2-stable | |
cd | |
wget https://github.com/pagespeed/ngx_pagespeed/archive/v${NPS_VERSION}.zip | |
unzip v${NPS_VERSION}.zip | |
cd ngx_pagespeed-${NPS_VERSION}/ | |
NPS_RELEASE_NUMBER=${NPS_VERSION/beta/} | |
NPS_RELEASE_NUMBER=${NPS_VERSION/stable/} | |
psol_url=https://dl.google.com/dl/page-speed/psol/${NPS_RELEASE_NUMBER}.tar.gz |
This file contains 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 apt-get update | |
sudo apt-get install -y software-properties-common | |
sudo add-apt-repository ppa:certbot/certbot | |
sudo apt-get update | |
sudo apt-get install -y python-certbot-nginx | |
# centos |
This file contains 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
# Check number of CPUs | |
grep ^processor /proc/cpuinfo | wc -l | |
# set maximum number of open files (current session) | |
ulimit -u 10000 | |
ulimit -n 10000 | |
# Modify number open files | |
vi /etc/security/limits.conf | |
# * soft nofile 64000 |
This file contains 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
#!/usr/bin/env python | |
""" | |
Tail a Jenkins build in a terminal | |
""" | |
import os | |
import requests | |
import sys | |
import time | |
This file contains 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
local cjson = require "cjson" | |
local jwt = require "resty.jwt" | |
local args = ngx.req.get_uri_args() | |
local token = args.BearerToken | |
if (args.bearerToken ~= nil) then | |
token = args.bearerToken | |
end |
This file contains 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
# switch to root user | |
sudo su | |
# Download openresty 1.13.6 | |
cd /tmp | |
wget https://openresty.org/download/openresty-1.13.6.1.tar.gz | |
tar -xvf openresty-1.13.6.1.tar.gz | |
#install necessary libs | |
apt-get install build-essential libxslt1-dev libxml2-dev libgd2-xpm-dev libgeoip-dev libgoogle-perftools-dev libperl-dev libpng-dev zlib1g-dev |
This file contains 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
# Export pages with range of a PDF file | |
s -dNOPAUSE -dBATCH -sDEVICE=png16m -r150 -dTextAlphaBits=4 -dGraphicsAlphaBits=4 -dPDFFitPage -dFirstPage=1 -dLastPage=10 -sOutputFile="Pic-%d.png" ESB-WSO2-Introduction.pdf | |
# Get total pages of a PDF file | |
gs -q -dNODISPLAY -c "(abc.pdf) (r) file runpdfbegin pdfpagecount = quit" |
OlderNewer