HowTo use the turnkey docker images to create a test Forest Admin project

This small tutorial was created by Bryan Stone and documents how to use the turnkey docker images to create a test project. Have fun!

1 - Seed & launch a demo database

docker run --rm -d --name turnkey forestadmin/turnkey-mysql


2 - Generate application using lumber against database

docker run --rm --name lumber \
--link turnkey \
-v `pwd`:/usr/src/app --init \
-e DATABASE_URL="mysql://turnkey:turnkey@turnkey:3306/turnkey" \
-e DATABASE_SSL="false" \
-e APP_NAME="Turnkey Demo" \
-e FOREST_EMAIL="************" \
-e FOREST_TOKEN="************" \
-e APPLICATION_HOST="localhost" \
-ti forestadmin/lumber


3 - We can kill the database container now, we’ll restart it later:

docker kill turnkey


4 - Open the generated Turnkey Demo application and edit the docker-compose.yml to add the database container to the stack:

    container_name: turnkey
    image: forestadmin/turnkey-mysql

5 - Now you can start the generated app with:

docker-compose up
1 Like