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
require 'curb' | |
require 'openssl' | |
require 'base64' | |
def coinex_call(url, data) | |
coinex_key = '' | |
coinex_secret = '' | |
if data != '' |
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
/** | |
* Magento EAV Entity Inspection | |
* Inspect Category | |
*/ | |
SET @entityid = '3'; | |
SELECT ea.attribute_id, ea.attribute_code, eav.value AS 'value', 'varchar' AS 'type' | |
FROM catalog_category_entity e | |
JOIN catalog_category_entity_varchar eav | |
ON e.entity_id = eav.entity_id |
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
#!/bin/bash | |
# random password generator by typedeaF | |
# This program has no "real" value other than introducing some bash concepts and putting them to use. | |
# to strip the comments: cat this.file | grep -v '^# ' | |
# Sets the maximum size of the password the script will generate | |
#MAXSIZE=16 | |
MAXSIZE="${1:-16}" |
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
Create /etc/profiles.d/colorps1.sh | |
#!/bin/bash | |
if [ $(id -u) -eq 0 >/dev/null 2>&1 ]; then | |
export PS1="\[\033[01;31m\]\u\[\033[00;37m\]@\h:\w\$ " | |
fi |
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
# http://codex.wordpress.org/Nginx | |
# nginx.conf | |
# Generic startup file. | |
user {user} {group}; | |
#ususally equal to number of CPU's you have. run command "grep processor /proc/cpuinfo | wc -l" to find it | |
worker_processes 2; | |
error_log /var/log/nginx/error.log; |
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
--- | |
# ^^^ YAML documents must begin with the document separator "---" | |
# | |
#### Example docblock, I like to put a descriptive comment at the top of my | |
#### playbooks. | |
# | |
# Overview: Playbook to bootstrap a new host for configuration management. | |
# Applies to: production | |
# Description: | |
# Ensures that a host is configured for management with Ansible. |
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
--- | |
# file: deploy_git.yml | |
- | |
hosts: "{{ hosts }}" | |
user: root | |
vars: | |
- project: "{{ project }}" | |
- repo: "{{ repo }}" | |
- releasedir: "{{ releasedir }}" | |
- run_composer: "{{ composer | default(false) }}" |
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
#!/bin/bash | |
# $Id: tunnel_bitcoind.sh 13-Oct-14 16:02:39 $ | |
# | |
# Shell script to create ssh port forwarded tunnel to remote server for | |
# localhost bitcoind rpc access. | |
# | |
# This script is not supported in any way. Use at your own risk. | |
# |
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
#!/bin/bash | |
if [ "$1" = "" ]; then | |
echo Current branch name required | |
exit; | |
fi | |
if [ "$2" = "stash" ]; then | |
echo "Stashing current state..." | |
git stash |
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
#!/bin/sh | |
ansible-playbook ~/bin/deploy_git.yml --extra-vars="hosts=ANSIBLE_HOST_GROUP project=PROJECT releasedir=SRV_RELASE_PATH repo=ssh://git@github.com/damonp/PROJECT.git" |
OlderNewer