Docker.app will complain about incompatible processor, so we will use Docker Machine.
Download Docker for Mac (Docker.app). It contains some binaries that are necessary.
brew install virtualbox docker-machine
#!/bin/bash -e | |
DIR=$PWD/work | |
mkdir -p ${DIR} | |
rm -f ${DIR}/*.tar.gz | |
LIBRESSL=libressl-2.4.5 | |
HAPROXY=haproxy-1.8.4 | |
PCRE=pcre-8.39 |
brew unlink thrift | |
brew install https://raw.githubusercontent.com/Homebrew/homebrew-core/16ebe5f1843e6cb54856311ff0f676be53007329/Formula/thrift.rb |
docker run -d -p 9000:9000 --name minio minio/minio server /export
docker logs minio
-- Create tables | |
CREATE TABLE groups (id serial NOT NULL, name character varying NOT NULL); | |
CREATE TABLE network_group_members (pid integer, cid integer NOT NULL); | |
-- Insert the groups | |
INSERT INTO groups (name) VALUES ('GROUP 1'),('GROUP 2'),('GROUP 3'),('GROUP 4'),('GROUP 5'),('GROUP 6'),('GROUP 7'),('GROUP 8'),('GROUP 9'),('GROUP 10'),('GROUP 11'),('GROUP 12'),('GROUP 13'); | |
-- Build the "Network" | |
INSERT INTO network_group_members(pid,cid) VALUES (1,2),(1,3),(1,4),(2,5),(5,6),(5,7),(7,8),(3,9),(4,10),(4,11),(11,12),(12,13); |
# take one | |
# subdirectory (one server, multiple services) | |
location /btsync/ { | |
rewrite ^/btsync/gui(.*) /btsync$1 last; | |
proxy_pass http://127.0.0.1:8888/gui/; | |
proxy_redirect /gui/ /btsync/; | |
proxy_buffering off; | |
proxy_set_header Host $host; | |
proxy_set_header X-Real-IP $remote_addr; |
# | |
# Slightly tighter CORS config for nginx | |
# | |
# A modification of https://gist.github.com/1064640/ to include a white-list of URLs | |
# | |
# Despite the W3C guidance suggesting that a list of origins can be passed as part of | |
# Access-Control-Allow-Origin headers, several browsers (well, at least Firefox) | |
# don't seem to play nicely with this. | |
# |