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 pymongo | |
from pymongo import Connection | |
from pymongo.dbref import DBRef | |
from pymongo.database import Database | |
# connect | |
connection = Connection() | |
db = Database(connection, "things") | |
# clean up |
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
#!/usr/bin/env python | |
import os | |
import shelve | |
import functools | |
import time | |
import collections | |
import argparse | |
from abc import ABCMeta, abstractmethod | |
SHELVE_DB_FILE = os.path.join(os.path.dirname(__file__), 'storage.shelve') |
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
arch -i386 pip install Skype4Py |
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
FROM mariadb:10.3 | |
ENV MYSQL_ROOT_PASSWORD=1111 MYSQL_DATABASE=db MYSQL_USER=user MYSQL_PASSWORD=1111 | |
ADD dump.sql /docker-entrypoint-initdb.d/db.sql |
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
# Locally: | |
git tag | grep -v "staging.*\|production.*" | xargs git tag -d | |
# Remote: | |
git tag | grep -v "staging.*\|production.*" | xargs -n 1 git push --delete origin |
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 python:3.7.7-slim-buster | |
RUN pip install \ | |
google-api-core[grpc,grpcgcp]==1.22.2 \ | |
google-cloud-core==1.4.1 \ | |
google-cloud-spanner==2.0.0 \ | |
googleapis-common-protos[grpc]==1.52.0 \ | |
grpc-google-iam-v1==0.12.3 \ | |
grpcio-gcp==0.2.2 \ |
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 python:3.7.7-slim-buster | |
RUN pip install \ | |
google-api-core[grpc,grpcgcp]==1.22.2 \ | |
google-cloud-core==1.4.1 \ | |
google-cloud-spanner==2.0.0 \ | |
googleapis-common-protos[grpc]==1.52.0 \ | |
grpc-google-iam-v1==0.12.3 \ | |
grpcio-gcp==0.2.2 \ |