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
| <?php | |
| header('Cache-Control: private'); | |
| phpinfo(); |
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
| # Install jq on Mac | |
| brew install jq | |
| brew install oath-toolkit | |
| # Install Perl module from CPAN | |
| perl -MCPAN -e 'install URI::Escape' | |
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
| #!/bin/sh | |
| # Forked from https://gist.github.com/dagelf/ab2bad26ce96fa8d79b0834cd8cab549 | |
| # With modifications for including timestamp and reporting in Megabits/s instead of Kilobytes/s | |
| # | |
| # To run: ./n.sh em1 | |
| SLP=60 # display / sleep interval | |
| DEVICE=$1 | |
| IS_GOOD=0 | |
| for GOOD_DEVICE in `grep \: /proc/net/dev | awk -F: '{print $1}'`; do |
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
| # Poll for various system stats for monitoring system | |
| # Just copy and paste the commands into a bash prompt | |
| # Use Ctrl-C to exit the polling | |
| # Defaults that can be overriden | |
| [[ -z "$REDIS_CONN" ]] && REDIS_CONN="-h 127.0.0.1 -p 6379" | |
| [[ -z "$SLEEP_SECONDS" ]] && SLEEP_SECONDS=60 | |
| # Header info | |
| CUR_TIME='timestamp' |
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
| # This fails the variable assignment because of the single quotes and spaces | |
| # and with this method single quotes have to be escaped | |
| PHP_CODE="initialized" | |
| PHP_CODE='<?php | |
| print 'hello '; | |
| print "world!"; | |
| print "\n"; | |
| ' | |
| echo "${PHP_CODE}" | php |
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
| # ElasticSearch Documentation | |
| # https://www.elastic.co/guide/en/elasticsearch/reference/current/getting-started.html | |
| # Initialize some variables | |
| ES_HOST="localhost" | |
| ES_PORT="9200" | |
| ES_USER="elastic" | |
| ES_PASS="changeme" | |
| # System Info |
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
| <?php | |
| $status_code = "200"; | |
| $reason_phrase = "OK"; | |
| # Status of responses including a Location header: 201, 301, 302, 303, 307, 308. | |
| # https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Location | |
| # https://tools.ietf.org/html/rfc2616#section-14.30 | |
| # Nginx interprets CGI response headers differently than Apache and if a location | |
| # header is found in a response not containing a standard status code it will override |
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
| <?php | |
| $ssh_host = "1.2.3.4"; | |
| $ssh_user = "my_ssh_username"; | |
| $ssh_tunnel_local_port = "3307"; | |
| $ssh_tunnel_remote_host = "127.0.0.1"; # DB Server IP on the remote network if not local to the remote system | |
| $ssh_tunnel_remote_port = "3306"; | |
| $local_mysql_host = "127.0.0.1"; | |
| $mysql_user = "my_mysql_username"; | |
| $mysql_pass = "my_secret_password"; | |
| $mysql_db_name = "my_database_name"; |
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
| #!/bin/sh | |
| ssh $1 | |
| while test $? -gt 0 | |
| do | |
| sleep 5 # highly recommended - if it's in your local network, it can try an awful lot pretty quick... | |
| echo "Trying again..." | |
| ssh $1 | |
| done |
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
| declare THREADS_TOTAL=4 # 600 | |
| declare TEST_SCENARIO_PER_BROWSE="25" # 90 | |
| declare TEST_SCENARIO_PER_ABANDONED_CART="25" # 5 | |
| declare TEST_SCENARIO_PER_CHECKOUT_GUEST="25" # 3 | |
| declare TEST_SCENARIO_PER_CHECKOUT_CUSTOMER="25" # 2 | |
| ############################################################ | |
| # Thread distribution calculation and validity checks | |
| ############################################################ |