{"id":23143603,"url":"https://github.com/digitalinteraction/make-place-example-stack","last_synced_at":"2026-01-18T12:19:35.982Z","repository":{"id":146137709,"uuid":"385868172","full_name":"digitalinteraction/make-place-example-stack","owner":"digitalinteraction","description":"Deprecated. Example of how to deploy make.place with Docker Compose.","archived":false,"fork":false,"pushed_at":"2021-07-14T08:29:16.000Z","size":20,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-09T22:11:15.265Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/digitalinteraction.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-07-14T08:28:53.000Z","updated_at":"2024-11-08T12:32:01.000Z","dependencies_parsed_at":null,"dependency_job_id":"b8a1580e-52b5-423c-8562-bdaa3e5da7bd","html_url":"https://github.com/digitalinteraction/make-place-example-stack","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digitalinteraction%2Fmake-place-example-stack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digitalinteraction%2Fmake-place-example-stack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digitalinteraction%2Fmake-place-example-stack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digitalinteraction%2Fmake-place-example-stack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/digitalinteraction","download_url":"https://codeload.github.com/digitalinteraction/make-place-example-stack/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247174467,"owners_count":20896078,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-17T15:13:50.309Z","updated_at":"2026-01-18T12:19:35.964Z","avatar_url":"https://github.com/digitalinteraction.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Example Make Place deployment stack\n\nAn example docker-compose stack used to deploy one or more instances of Make Place.\nFork this repo to create your own for your stack, to contains all of your instances.\n\n## Features\n\n* Automatic nginx reverse proxy generation\n* Automatic (free) SSL certificate generation\n* Secure by default, your secrets are only ever on your server\n* Containerised, each deployment is separate and cannot interaction with each other\n* Scalable, add more deployments by modifying Yaml files\n* Optional GitLab pipeline to automatically deploy when you push changes\n\n## Prerequisites\n\n* Working knowledge of MySQL, Bash, SSH \u0026 Git\n\n## System requirements\n\n* Docker\n* docker-compose\n\n## How it works\n\n1. You have your repo fork checked out locally and on the server.\n2. You have the repo checked out on the server with your secrets filled in.\n3. To make deployments you configure your `docker-compose.yml` locally and push it to git.\n4. You can run `ssh user@server.io deploy deployment-a deployment-b` to deploy changes,\n    which could be executed from a continuous deployment pipeline.\n\n## Local setup\n\nFollow these steps to setup a local repository, where `$YOUR_REPO` is the git url of your fork.\n\n```bash\n# Clone your repo fork locally\ngit clone $YOUR_REPO\n\n# Get the latest nginx template\ncurl https://raw.githubusercontent.com/jwilder/nginx-proxy/master/nginx.tmpl -o nginx.tmpl.conf\n\n# Make the example .gitignore a real one\nmv example.gitignore .gitignore\n\n# Configure your deployments (see below)\n\n# Push the changes\ngit add -A\ngit commit -m \":rocket: Configuring stack\"\ngit push -u origin master\n```\n\n## Deployment configuration\n\nDeployments are defined as services in the `docker-compose.yml` at the bottom.\nTo add a deployment, copy/replace the `pug-spotter` service and make the following changes:\n\n1. Setup an assets volume\n    1. Set `pugs_assets` to something unique\n    2. Add it as an entry to the root level `volumes` at the top\n2. Set `secrets/pugs.env` to a new secrets filename\n3. Configure the deployment's environment\n    * Set `VIRTUAL_HOST` \u0026 `LETSENCRYPT_HOST` to your domain\n    * Set `LETSENCRYPT_EMAIL` to your email address to receive letsencrypt errors\n    * See the [platform repo](https://github.com/make-place/php-platform/blob/master/README.md#environment-variables) for instance configuration\n\n## Server setup\n\nFollow these steps to set up a Make Place server, using your stack repo,\nwhere $YOUR_USERNAME is the user you sign in with, e.g. `root` or `rob`.\n\n\u003e You can use the user commands later to set up a `deploy` user in server group\n\n```bash\n# Connect to your server\nssh root@my-server.io\n\n# Setup a server usergroup\nsudo groupadd server\nsudo usermod -aG docker,server $YOUR_USERNAME\n\n# Create a stack directory \u0026 give it group-based permissions\nmkdir /srv/stack\nsudo chown -R $YOUR_USERNAME:server /srv/stack\nsudo chmod -R g+ws /srv/stack\n\n# Setup the directory\ncd /srv/stack\ngit clone $YOUR_REPO\n\n# Create any .env files at this point\n# i.e. recreate your local secrets/ folder on the server\n# Ensure to set mysql.env's root password and remember this value\n\n# Startup the core core containers\ndocker-compose up -d nginx nginx-gen letsencrypt mysql\n\n# Configure your mysql now (i.e. with a GUI like Sequel Pro)\n# Add a databases for each deployment and one for the geo service \u0026 access\n# You should have access with username `root` and the password from above\n\n# Fill in your .env files with credentials, see secrets/ for what should be set\n\n# Start up the rest of the server\ndocker-compose up -d\n\n# Setup the deploy script for CI/CD\nsudo ln -s deploy.sh /usr/bin/deploy\nsudo chmod +x /usr/bin/deploy\n\n# Setup your geography service\n# ref: https://github.com/make-place/geography#sample-deployment\n\n# Your server is up and running\n```\n\n## First deployment setup\n\nWhen you have just added a deployment, follow these steps on the server:, where $DEPLOYMENT is your deployment name \u0026 $URL is it's url.\n\n```bash\n# Go to the stack\ncd /srv/stack\n\n# un-comment \u0026 set DEFAULT_USER \u0026 DEFAULT_PASS temporarily\nnano secrets/$DEPLOYMENT.env\n\n# Restart the container\ndocker-compose up -d $DEPLOYMENT\n\n# Setup the deployment, performing migrations and setting up the cache\n# You can sign in with the details your put in $DEPLOYMENT.env\nopen $URL/dev/build?flush\n\n# Visit /admin and set your user's password to a secure password\nopen $URL/admin\n\n# Re-comment DEFAULT_USER \u0026 DEFAULT_PASS in $DEPLOYMENT.env\nnano secrets/$DEPLOYMENT.env\n\n# Restart the container\ndocker-compose up -d $DEPLOYMENT\n\n# Your deployment is up and running\n# You can configure it through the CMS\n```\n\n## Updating a deployment\n\n```bash\n# For example, deploy pug-spotter \u0026 holding site after updating $YOUR_REPO\nssh rob@make.place deploy pug-spotter holding-site\n```\n\n## Further work \u0026 ideas\n\n* Separate core \u0026 deployment services into 2 docker-compose files\n* Setup continuous integration with GitLab with a `deploy` user\n* Modify your `nginx.tmpl.conf` to use a custom error page\n* Update `sites.yml` to reflect new deployments\n* Add to `redirs.conf` to implement custom nginx redirects\n* Use the `mkpl/static-pages` docker image to add holding sites\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdigitalinteraction%2Fmake-place-example-stack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdigitalinteraction%2Fmake-place-example-stack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdigitalinteraction%2Fmake-place-example-stack/lists"}