Redis has a feature called lists. The lists can be treated as a stack where elements can be pushed onto or popped from. There are several calls which help you to manage such lists. Once nice feature is the blpop command which does a blocking call on the queue. Therefore it's a nice and elegant way to implement a queue systems for tasks.
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
# | |
# A plugin to setup capture interfaces | |
# The plugin is off by default. To enable it, add "interfacesetup.enabled=1" to broctl.cfg. | |
# | |
import BroControl.plugin | |
class InterfaceSetupPlugin(BroControl.plugin.Plugin): | |
def __init__(self): | |
super(InterfaceSetupPlugin, self).__init__(apiversion=1) |
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
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
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
sudo su - | |
mkdir -p /opt/bin | |
curl -L https://github.com/docker/compose/releases/download/1.9.0/docker-compose-`uname -s`-`uname -m` > /opt/bin/docker-compose | |
chmod +x /opt/bin/docker-compose |
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 | |
if [[ "$TRAVIS_PULL_REQUEST" != "false" ]]; then | |
echo "This is a pull request. No deployment will be done." | |
exit 0 | |
fi | |
if [[ "$TRAVIS_BRANCH" != "master" ]]; then | |
echo "Testing on a branch other than master. No deployment will be done." | |
exit 0 | |
fi |
See how a minor change to your commit message style can make a difference. Examples
Have a look at CLI util git-conventional-commits to ensure this conventions and generate changelogs