国内从 Docker Hub 拉取镜像有时会遇到困难,此时可以配置镜像加速器。
Dockerized 实践 https://github.com/y0ngb1n/dockerized
国内从 Docker Hub 拉取镜像有时会遇到困难,此时可以配置镜像加速器。
Dockerized 实践 https://github.com/y0ngb1n/dockerized
$ git clone [email protected]:xxxxx/xxxx.git my-awesome-proj | |
Cloning into 'my-awesome-proj'... | |
ssh: connect to host github.com port 22: Connection timed out | |
fatal: Could not read from remote repository. | |
$ # This should also timeout | |
$ ssh -T [email protected] | |
ssh: connect to host github.com port 22: Connection timed out | |
$ # but this might work |
#coding: utf-8 | |
import sys | |
if sys.getdefaultencoding() != 'utf-8': | |
reload(sys) | |
sys.setdefaultencoding('utf-8') | |
import json | |
import re | |
from urllib import quote | |
from datetime import datetime |
########## Install NGINX ############## | |
# Install software-properties-common package to give us add-apt-repository package | |
sudo apt-get install -y software-properties-common | |
# Install latest nginx version from community maintained ppa | |
sudo add-apt-repository ppa:nginx/stable | |
# Update packages after adding ppa |
As of January 2018, Raspbian does not yet include the latest Python release, Python 3.6. This means we will have to build it ourselves, and here is how to do it. There is also an ansible role attached that automates it all for you.
In order to run this image do:
docker-compose up -d
to get all up.
On first run DB initialization and initial user setup is done like so:
First start a bash in the container: docker-compose exec sentry /bin/bash
.
Then, inside bash, do sentry upgrade
wait until it asks you for an inital user.
When finished exit
the bash.
When in doubt check with docker-compose ps
if all went fine.
import Foundation | |
struct Regex { | |
var pattern: String { | |
didSet { | |
updateRegex() | |
} | |
} | |
var expressionOptions: NSRegularExpressionOptions { | |
didSet { |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.