diff --git a/README.md b/README.md index b6d1954..7f5ede2 100644 --- a/README.md +++ b/README.md @@ -2,11 +2,26 @@ A program to take notes during a sermon. The web app was built with PHP and Symfony. +## ATTN: !!!!BREAKING CHANGE!!!! v1.0 -> v1.1 + +This was my first publicly available docker container so I did not realize what some decisions would do. If you are upgrading from v1 you first need to save your database OR you will lose all your current notes!! Follow the steps below to do that + +1. You need to make sure that you have a running SSH server on your host computer +2. On your host computer, `docker exec -it sermon-notes bash` +3. `cd var/` +4. `scp data.db {user}@{host computer IP}:{path}` +5. Authenticate with the password +6. This will copy the file over SFTP to the host computer +7. After this then you run the `docker run...` command in Step 1 of the `Installation` instructions below, once the container is running you need to copy the `data.db` file into the working directory of the docker container. + - For example, if you have `~/docker/sermon-notes` as the path for the container on the host computer, you'll copy the `data.db` to `~/docker/sermon-notes/data` + ## Installation -1. Run `docker run -d --name sermon-notes -p 80:80 ryanprather/sermon-notes:latest`, this will download and start the container and keep it running in the background. If you already have something on port 80 change the first `80` to whatever open port you'd like. -2. Run `docker exec -it sermon-notes bash install.sh` This will run an install script to create an .env file specific to your install, populate with the beginning factors, and then run a `composer` command to download the necessary package dependancies. -3. Once complete you have a running system that you can navigate to in your browser with `http://{ip}:{port}|{hostname}:{port}`. Then you just need to register for an account. The first account that is created is made an admin so that you can access the `Reference Editor` and update any reference material if necessary. +1. Make a directory in your desired docker storage folder (e.g. `~/docker/sermon-notes`), then `cd` into it. +2. Create a file called `.env` in that folder, no need to add anything to it right now. +3. Run `docker run -d --name sermon-notes -p 80:80 -v $PWD/data:/data -v $PWD/.env:/var/www/html/.env ryanprather/sermon-notes:latest`, this will download and start the container and keep it running in the background. If you already have something on port 80 change the first `80` to whatever open port you'd like. +4. Run `docker exec -it sermon-notes bash install.sh` This will run an install script to create an .env file specific to your install, populate with the beginning factors, and then run a `composer` command to download the necessary package dependancies. +5. Once complete you have a running system that you can navigate to in your browser with `http://{ip}:{port}`|`http://{hostname}:{port}`. Then you just need to register for an account. The first account that is created is made an admin so that you can access the `Reference Editor` and update any reference material if necessary. ## Operation