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
import email.utils | |
from requests.packages.urllib3.packages import six | |
def format_header_param(name, value): | |
""" | |
Helper function to format and quote a single header parameter. | |
Particularly useful for header parameters which might contain | |
non-ASCII values, like file names. This follows RFC 2231, as |
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 | |
echo "deb http://apt.opscode.com/ `lsb_release -cs`-0.10 main" | tee /etc/apt/sources.list.d/opscode.list | |
mkdir -p /etc/apt/trusted.gpg.d | |
gpg --keyserver keys.gnupg.net --recv-keys 83EF826A | |
gpg --export [email protected] | sudo tee /etc/apt/trusted.gpg.d/opscode-keyring.gpg > /dev/null | |
apt-get update | |
apt-get install opscode-keyring -y | |
apt-get upgrade -y | |
apt-get install chef -y |
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
from selenium import webdriver | |
from selenium.webdriver.remote.remote_connection import RemoteConnection | |
from selenium.webdriver.remote.errorhandler import ErrorHandler | |
from selenium.webdriver.remote.command import Command | |
class PersistentWebdriver (webdriver.Remote): | |
def __init__(self, session_id=None, browser_name=''): | |
command_executor='http://localhost:4444/wd/hub' |