I tested all of these projects on my dokku-alt server!
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
exec { 'pull-changes': | |
# This unless command makes it so this exec only runs when the branch is behind the head | |
unless => [ | |
"/bin/bash -c 'cd /var/www/django/django \ | |
&& CURRBRANCH=$(/usr/bin/git rev-parse --abbrev-ref HEAD)\ | |
&& /usr/bin/git fetch origin \$CURRBRANCH \ | |
&& /usr/bin/git rev-list HEAD...origin/\$CURRBRANCH --count'\ | |
| /bin/grep '0'" | |
], |
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
# Clones a repository from our github | |
# Info: https://github.com/puppetlabs/puppetlabs-vcsrepo/blob/master/README.GIT.markdown | |
class web::repo ($revision, $latest=false) { | |
# Git is used to install our repositories | |
ensure_resource('package', 'git', {'ensure' => 'present'}) | |
class { 'ssh::client': | |
storeconfigs_enabled => 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
# Enable ssh tunneling on remote server | |
GatewayPorts yes | |
ClientAliveInterval 30 | |
ClientAliveCountMax 99999 | |
# Example tunnel from local server | |
# $ ssh -R8081:127.0.0.1:8080 root@example.com | |
# $ curl example.com:8081 |
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 | |
generic_handler () { | |
kill -s $1 $PID | |
while kill -0 $PID &>/dev/null | |
do | |
wait $PID | |
done | |
} |
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 | |
# This is a little script that will install the required puppet modules. | |
# It was written to help setup vagrant. It is called as a provision script. | |
# | |
# # This installs the modules | |
# config.vm.provision :shell do |shell| | |
# shell.path = "./puppet/install_puppet_modules.sh" | |
# 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
videojs.BigPlayButton.prototype.onClick = function(){ | |
if(this.player_.paused()) { | |
this.player_.play(); | |
} else { | |
this.player_.pause(); | |
} | |
}; |
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 swapon -s | |
free -m | |
df -h | |
# 2G, 4G, etc | |
sudo fallocate -l 2G /swapfile | |
ls -lh /swapfile | |
sudo chmod 600 /swapfile | |
ls -lh /swapfile | |
sudo mkswap /swapfile | |
sudo swapon /swapfile |
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
<?php include 'protect.php';?> | |
<!DOCTYPE html> | |
<html> | |
<head></head> | |
<body>Secrets. </body> | |
</html> |
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
>git commit -a -m 'add index' | |
gi[master 5377c90] add index | |
1 file changed, 547 insertions(+) | |
create mode 100755 public/vf/index.html | |
>git push sandbox master | |
Counting objects: 7, done. | |
Delta compression using up to 8 threads. | |
Compressing objects: 100% (4/4), done. |