From ee26e2c40d304d5cebe43380be4b06ebd8326a7b Mon Sep 17 00:00:00 2001 From: Scott Koranda Date: Thu, 25 May 2017 15:57:46 -0500 Subject: [PATCH] README.md for docs --- docs/README.md | 30 +++++ recipes/simple-no-persistence/README.md | 111 ---------------- recipes/simple-with-persistence/README.md | 149 ---------------------- 3 files changed, 30 insertions(+), 260 deletions(-) create mode 100644 docs/README.md delete mode 100644 recipes/simple-no-persistence/README.md delete mode 100644 recipes/simple-with-persistence/README.md diff --git a/docs/README.md b/docs/README.md new file mode 100644 index 0000000..60c2574 --- /dev/null +++ b/docs/README.md @@ -0,0 +1,30 @@ + + +# COmanage Registry Docker Documentation + +* [Persist data using host-mounted volumes](docs/basic-auth-postgres-persist.md) +* [Use MariaDB instead of PostgreSQL](docs/basic-auth-mariadb-persist.md) +* [Add OpenLDAP slapd for provisioning](docs/openldap-slapd.md) +* [Advanced configuration](docs/advanced-configuration.md) +* [Complete example recipe for production deployment](docs/shibboleth-sp-postgres-compose.md) +* [Using Docker service stacks and Docker secrets](docs/stacks-secrets.md) + diff --git a/recipes/simple-no-persistence/README.md b/recipes/simple-no-persistence/README.md deleted file mode 100644 index 4728c85..0000000 --- a/recipes/simple-no-persistence/README.md +++ /dev/null @@ -1,111 +0,0 @@ - - -# COmanage Registry Docker Simple Evaluation No Persistence - -Follow this recipe to spin up an evaluation instance of COmanage Registry -that uses basic authentication with a pre-set login and password. Do *not* -use this recipe for any deployment with security requirements. - -This recipe will *not* persist data. All data will be lost when the containers -are removed. - -## Recipe - -Begin by creating an internal network for the containers to use: - -``` -docker network create --driver=bridge \ - --subnet=192.168.0.0/16 \ - --gateway=192.168.0.100 \ - comanage-registry-internal-network -``` - -Next build a PostgreSQL image to use as the database container: - -``` -pushd comanage-registry-postgres -docker build -t comanage-registry-postgres . -``` - -Start the database container: - -``` -docker run -d --name comanage-registry-database \ - --network comanage-registry-internal-network \ - comanage-registry-postgres -``` - -Next build the COmanage Registry image using basic authentication: - -``` -popd -pushd comanage-registry-basic-auth -export COMANAGE_REGISTRY_VERSION=hotfix-2.0.x -sed -e s/%%COMANAGE_REGISTRY_VERSION%%/${COMANAGE_REGISTRY_VERSION}/g \ - Dockerfile.template > Dockerfile -docker build \ - -t comanage-registry:${COMANAGE_REGISTRY_VERSION}-basic-auth . -``` - -Start the COmanage Registry container: - -``` -docker run -d --name comanage-registry \ - --network comanage-registry-internal-network \ - -p 80:80 -p 443:443 \ - comanage-registry:${COMANAGE_REGISTRY_VERSION}-basic-auth -``` - -The COmanage Registry service is now exposed on the host on which -Docker is running on ports 80 and 443. For example on your localhost - -``` -https://localhost/registry/ -``` - -You will need to click through browser warnings about self-signed -certificates for HTTPS. - -Click "Login" to login to the registry. For credentials use - -``` -login : registry.user -password : password -``` - -The following sections in the [COmanage Registry Technical Manual](https://spaces.internet2.edu/display/COmanage/COmanage+Technical+Manual) -may be helpful: - -* [Setting Up Your First CO](https://spaces.internet2.edu/x/F4DPAg) -* [Understanding Registry People Types](https://spaces.internet2.edu/x/RgGnAQ) -* [Registry Administrators](https://spaces.internet2.edu/x/EIDPAg) -* [Registry Enrollment Flow Configuration](https://spaces.internet2.edu/x/RAGnAQ) - -To stop the containers and destroy the network: - -``` -docker stop comanage-registry -docker stop comanage-registry-database -docker network rm comanage-registry-internal-network -``` - - diff --git a/recipes/simple-with-persistence/README.md b/recipes/simple-with-persistence/README.md deleted file mode 100644 index f723198..0000000 --- a/recipes/simple-with-persistence/README.md +++ /dev/null @@ -1,149 +0,0 @@ - - -# COmanage Registry Docker Simple Evaluation With Persistence - -Follow this recipe to spin up an evaluation instance of COmanage Registry -that uses basic authentication with a pre-set login and password. Do *not* -use this recipe for any deployment with security requirements. - -This recipe *will* persist data outside of containers. - -## Recipe - -Begin by creating a directories for the relational database and COmanage -Registry to use to persist data: - -``` -mkdir /opt/comanage-registry-database -mkdir /opt/comanage-registry-local -``` - -Next use the `htpasswd` command to generate a password file to be used -with basic authentication. When prompted enter your chose password (twice): - -``` -htpasswd /opt/comanage-registry-passwords registry.admin -``` - -You may edit that file later to either change the password or add -credenitals for more users. - -Next create an internal network for the containers to use: - -``` -docker network create --driver=bridge \ - --subnet=192.168.0.0/16 \ - --gateway=192.168.0.100 \ - comanage-registry-internal-network -``` - -Next build a PostgreSQL image to use as the database container: - -``` -pushd comanage-registry-postgres -docker build -t comanage-registry-postgres . -``` - -Start the database container and mount the directory you created -for persisting data: - -``` -docker run -d --name comanage-registry-database \ - --network comanage-registry-internal-network \ - -v /opt/comanage-registry-database:/var/lib/postgresql/data \ - comanage-registry-postgres -``` - -Next build the COmanage Registry image using basic authentication: - -``` -popd -pushd comanage-registry-basic-auth -export COMANAGE_REGISTRY_VERSION=hotfix-2.0.x -sed -e s/%%COMANAGE_REGISTRY_VERSION%%/${COMANAGE_REGISTRY_VERSION}/g \ - Dockerfile.template > Dockerfile -docker build \ - -t comanage-registry:${COMANAGE_REGISTRY_VERSION}-basic-auth . -``` - -Start the COmanage Registry container and mount the directory you -created for persisting configuration data and the password file -you created for basic authentication: - -``` -docker run -d --name comanage-registry \ - --network comanage-registry-internal-network \ - -v /opt/comanage-registry-loca:/local \ - -v /opt/comanage-registry-passwords:/etc/apache2/passwords \ - -p 80:80 -p 443:443 \ - comanage-registry:${COMANAGE_REGISTRY_VERSION}-basic-auth -``` - -The COmanage Registry service is now exposed on the host on which -Docker is running on ports 80 and 443. For example on your localhost - -``` -https://localhost/registry/ -``` - -You will need to click through browser warnings about self-signed -certificates for HTTPS. - -Click "Login" to login to the registry. For credentials use `registry.admin` -and the password you previously set using the `htpasswd` command. - -To stop the containers: - -``` -docker stop comanage-registry -docker stop comanage-registry-database -``` - -You may edit the COmanage Registry configuration details in -`/opt/comanage-registry-local/Config` and then restart the containers. -For example to enable Registry to send email edit the file - -`/opt/comanage-registry-local/Config/email.php` and then restart the containers: - -``` -docker start comanage-registry-database -docker start comanage-registry -``` -The following sections in the [COmanage Registry Technical Manual](https://spaces.internet2.edu/display/COmanage/COmanage+Technical+Manual) -may be helpful: - -* [Setting Up Your First CO](https://spaces.internet2.edu/x/F4DPAg) -* [Understanding Registry People Types](https://spaces.internet2.edu/x/RgGnAQ) -* [Registry Administrators](https://spaces.internet2.edu/x/EIDPAg) -* [Registry Enrollment Flow Configuration](https://spaces.internet2.edu/x/RAGnAQ) - -To stop the containers and destroy the network: - -``` -docker stop comanage-registry -docker rm comanage-registry - -docker stop comanage-registry-database -docker rm comanage-registry-database - -docker network rm comanage-registry-internal-network -```