Skip to content
This repository has been archived by the owner on Aug 15, 2022. It is now read-only.

Commit

Permalink
config: retire boot2docker
Browse files Browse the repository at this point in the history
  • Loading branch information
cihangir committed Oct 6, 2017
1 parent 422985e commit 85afcee
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 36 deletions.
1 change: 0 additions & 1 deletion Brewfile
Expand Up @@ -3,5 +3,4 @@ install node
install go
install mongodb
install nginx
install boot2docker
install graphicsmagick
7 changes: 1 addition & 6 deletions README.development.markdown
Expand Up @@ -47,13 +47,8 @@ $ brew install homebrew/versions/node010
```

```
$ brew install boot2docker docker graphicsmagick mongodb nginx postgresql
$ brew install docker graphicsmagick mongodb nginx postgresql
$ npm i coffee-script@1.12.2 gulp -g
$ boot2docker init && boot2docker up
$ cat >>~/.bash_profile <<EOF
eval $(boot2docker shellinit)
EOF
$ . ~/.bash_profile
```

### Deploy Koding locally
Expand Down
2 changes: 1 addition & 1 deletion README.kdonkd.markdown
@@ -1,6 +1,6 @@
# Connect Koding on Koding

We’ve moved development of koding.com from our local machines to team on koding.com. It’s a big undertaking, but it’s necessary to do it to understand the day to day experience of using teams on koding.com. Support for local development (boot2docker) is now deprecated and will be removed very soon.
We’ve moved development of koding.com from our local machines to team on koding.com. It’s a big undertaking, but it’s necessary to do it to understand the day to day experience of using teams on koding.com.

You should have been invited to [team.koding.com](https://team.koding.com) already. Please do the following:

Expand Down
18 changes: 0 additions & 18 deletions config/generateRunFile.coffee
Expand Up @@ -238,13 +238,6 @@ generateDev = (KONFIG, options) ->
check_api_consistency
check_service_dependencies
if [[ `uname` == 'Darwin' ]]; then
if [ -z "$DOCKER_HOST" ]; then
echo "You need to export DOCKER_HOST, run 'boot2docker up' and follow the instructions. (or run 'eval $(docker-machine env default)')"
exit 1
fi
fi
mongo $KONFIG_MONGO --eval "db.stats()" > /dev/null # do a simple harmless command of some sort
RESULT=$? # returns 0 if mongo eval succeeds
Expand Down Expand Up @@ -282,7 +275,6 @@ generateDev = (KONFIG, options) ->
if [[ `uname` == 'Darwin' ]]; then
brew info graphicsmagick >/dev/null 2>&1 || { echo >&2 "I require graphicsmagick but it's not installed. Aborting."; exit 1; }
command -v boot2docker >/dev/null 2>&1 || command -v docker-machine >/dev/null 2>&1 || { echo >&2 "I require boot2docker but it's not installed. Aborting."; exit 1; }
elif [[ `uname` == 'Linux' ]]; then
command -v gm >/dev/null 2>&1 || { echo >&2 "I require graphicsmagick but it's not installed. Aborting."; exit 1; }
fi
Expand Down Expand Up @@ -417,13 +409,6 @@ generateDev = (KONFIG, options) ->
docker exec -i -t $id bash -l -c $2
}
function run_docker_wrapper () {
if [[ `uname` == 'Darwin' ]]; then
command -v boot2docker >/dev/null 2>&1 && boot2docker up
command -v docker-machine >/dev/null 2>&1 && docker-machine start default || echo 1
fi
}
function k8s () {
params=(start stop)
param=$1
Expand Down Expand Up @@ -568,7 +553,6 @@ generateDev = (KONFIG, options) ->
}
function build_services () {
run_docker_wrapper
# Build postgres
pushd $KONFIG_PROJECTROOT/go/src/socialapi/db/sql
Expand All @@ -593,8 +577,6 @@ generateDev = (KONFIG, options) ->
function services () {
run_docker_wrapper
EXISTS=$(docker inspect --format="{{ .State.Running }}" $SERVICES 2> /dev/null)
if [ $? -eq 1 ]; then
echo ""
Expand Down
3 changes: 1 addition & 2 deletions config/main.default.coffee
Expand Up @@ -13,8 +13,7 @@ Configuration = (options = {}) ->
main: options.host ? 'dev.koding.com'
port: '8090'

options.boot2dockerbox or= if os.type() is 'Darwin' then '192.168.59.103' else '127.0.0.1'
options.serviceHost or= options.boot2dockerbox
options.serviceHost or= '127.0.0.1'
options.publicPort or= '8090'
options.hostname or= 'dev.koding.com'
options.protocol or= 'http:'
Expand Down
3 changes: 1 addition & 2 deletions config/main.dev.coffee
Expand Up @@ -13,8 +13,7 @@ Configuration = (options = {}) ->
main: options.host ? 'dev.koding.com'
port: '8090'

options.boot2dockerbox or= if os.type() is 'Darwin' then '192.168.59.103' else '127.0.0.1'
options.serviceHost or= options.boot2dockerbox
options.serviceHost or= '127.0.0.1'
options.publicPort or= '8090'
options.hostname or= 'dev.koding.com'
options.protocol or= 'http:'
Expand Down
11 changes: 5 additions & 6 deletions configure
Expand Up @@ -85,12 +85,11 @@ rest = ->
log "------------------"
log "MAC INSTALL INSTRUCTIONS"
log "------------------"
log "1) install Docker, do `boot2docker init`, `boot2docker up`"
log "2) export DOCKER_HOST as tcp://192.168.59.103:2375"
log "3) brew install mongodb nginx"
log "4) do './run install' "
log "5) do './run buildservices' to create backend service containers after installing docker."
log "6) you can then type './run' to run Koding and see it on #{options.hostname}"
log "1) install Docker"
log "2) brew install mongodb nginx"
log "3) do './run install' "
log "4) do './run buildservices' to create backend service containers after installing docker."
log "5) you can then type './run' to run Koding and see it on #{options.hostname}"

(require "./deployment/socialapiconfig.coffee").create KONFIG
(require "./deployment/mongomigrationconfig.coffee").create KONFIG
Expand Down

0 comments on commit 85afcee

Please sign in to comment.