Closed davoclavo closed 7 years ago
I'm setting up a clean raspbian SD card to test that this:
@Spaghet please re-review. I made a few minor changes to make this work for the developer install. (I'm still testing docker). https://github.com/OpenAgInitiative/openag_brain/pull/338/commits/700efeed70bc13219bfbc9b5623efde1172bed72
Fix Dockerfile
Currently the Dockerfile is broken due to changes to the install scripts. The Dockerfile now mostly relies on
scripts/install_dev
, and due to its dependency on resin's raspbian image, a couple of bits had to be modified.I think relying on
scripts/install_dev
is not the best way to solve this, but it works in the interim, and it keeps the docker and non-docker builds rely on the same installation script. The reason why I say is not the best solution is that then docker can't leverage caching builds between commands, so every time a change is made inscript/install_dev
, the whole step has to be re-built, which takes a long time. Also, changes to other files thatinstall_dev
relies on (likeinit_dev
) probably won't be picked up in order to expire the cache, so could potentially cause troubles while debugging docker builds.Move couchdb related stuff out of
scripts/init_dev
db_bootstrap/db_config.py
scripts/install_db
script.Add docker-compose.yml
This file originally lived at the openag_brain_docker_rpi repo, but probably was lost in the transition to the monorepo. I think it is super useful to have it, and it is still mentioned a couple times in the docs.
NOTE - The docker image in docker hub should be updated by one of the admins in order for docker-compose to build from it.
Testing
In order to test, make sure you have installed docker and docker-compose
./openag_brain/scripts/install_docker
Then build the containers and start the application - This step will take a while, and you should be able to see progress in the logs.
docker-compose up -d
Docker cheatsheet