{"id":18403985,"url":"https://github.com/achekulaev/rc-lde","last_synced_at":"2026-07-18T07:08:08.903Z","repository":{"id":88670327,"uuid":"330527848","full_name":"achekulaev/rc-lde","owner":"achekulaev","description":"Remote-Containers Local Development Environment (LAMP + NodeJS)","archived":false,"fork":false,"pushed_at":"2021-01-18T03:03:30.000Z","size":46,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-23T20:48:06.796Z","etag":null,"topics":["vscode-remote"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/achekulaev.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":"ROADMAP.md","authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-01-18T01:52:40.000Z","updated_at":"2021-04-02T18:27:59.000Z","dependencies_parsed_at":null,"dependency_job_id":"a611a62d-342a-43d0-bee6-af2052cab5ae","html_url":"https://github.com/achekulaev/rc-lde","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/achekulaev/rc-lde","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/achekulaev%2Frc-lde","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/achekulaev%2Frc-lde/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/achekulaev%2Frc-lde/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/achekulaev%2Frc-lde/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/achekulaev","download_url":"https://codeload.github.com/achekulaev/rc-lde/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/achekulaev%2Frc-lde/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35609479,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-18T02:00:07.223Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["vscode-remote"],"created_at":"2024-11-06T02:49:35.121Z","updated_at":"2026-07-18T07:08:08.886Z","avatar_url":"https://github.com/achekulaev.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Remote-Containers Local Development Environment\n\nThis is Local Development Environment pattern that uses pre-configured [devcontainer](https://github.com/microsoft/vscode-dev-containers) to easily spin-up full-fledged local LAMP development environment (suitable for WordPress and Drupal), based on prepared Docker Compose files (for easy extension) and additional automation to easily change PHP/MySQL settings.\n\nFollowing this pattern helps running the same project on any OS with [maximum file system performance](#file-system-performance) or adding comprehensive cross-platform automation for repetitive operations.\n\n## Requirements\n\n| MacOS | Linux | Windows |\n|-------|-------|---------|\n| [Visual Studio Code](https://code.visualstudio.com/) | [Visual Studio Code](https://code.visualstudio.com/) | [Visual Studio Code](https://code.visualstudio.com/) |\n| [Remote-Containers extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) | [Remote-Containers extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) | [Remote-Containers extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) |\n| [Docker Desktop](https://www.docker.com/products/docker-desktop) | `docker` and `docker-compose` | [Docker Desktop](https://www.docker.com/products/docker-desktop)\n| | | [WSL2 with presetup](https://code.visualstudio.com/blogs/2020/07/01/containers-wsl)\n\n## Quick Start\n\nCopy whole `.devcontainer` folder into your workspace root and run [Remote-Containers: Open Folder in Container](https://code.visualstudio.com/docs/remote/containers#_quick-start-open-an-existing-folder-in-a-container) command on it. \nWeb Server will be available on `http://0.0.0.0:8080/`. You can change the port in the `docker-compose.yml`.\n\n\n| Path | Purpose |\n|------|---------|\n| `devcontainer.json` | Main devcontainer [configuration file](https://code.visualstudio.com/docs/remote/devcontainerjson-reference) \n| `docker-compose.yml` | Main [Compose file](https://docs.docker.com/compose/compose-file/compose-file-v3/) used in `devcontainer.json` \n| `docker-compose.named-volume.yml` | An [extension Compose file](https://docs.docker.com/compose/reference/overview/#specifying-multiple-compose-files) that can be included for best FS performance (see [File System Performance](#file-system-performance) for details)\n| `Dockerfile.lamp` | Dockerfile for `lamp` service, the main service in the `docker-compose.yml`\n| `devcontainer.env` | Env file to set/override environment variables (see [Environment Variables](#environment-variables) for details)\n| `post-create-command.sh` | Script that runs after container creation (via [postCreateCommand](https://code.visualstudio.com/docs/remote/devcontainerjson-reference))\n| `rcm` | CLI utility to quickly perform additional operations on the Devcontainer (requires Node.js)\n| `config/` | Config overrides for PHP and Maria/MySQL (see [Customize Container Configuration](#customize-container-configuration))\n| `package-lock.json`, `node_modules` | `rcm` utility dependencies\n\n## File System Performance\n\nBy default project files are bind-mounted into the folder called `/workspace` inside `lamp` container. \n`/workspace` is in turn symlinked as `/var/www/html` (the Apache document root).\nBind mount is a straightforward setup giving you near-instant changes between local and remote.\n\nHowever since Docker runs in a virtual machine on MacOS and Windows, bind volumes can be slow on large projects (despite being mounted as `delegated` in this pattern for best bind volume performance).\n(see [Advanced Containers](https://code.visualstudio.com/docs/remote/containers-advanced) for reference on volumes performance, and other advanced devcontainer tips).\n\nFor those who needs the best performance on MacOS and Windows, this pattern includes `docker-compose.named-volume.yml` that you can add to the `dockerComposeFile` array in the `devcontainer.json` file and start or rebuild the container.\n\n```json\n    {\n        \"name\": \"My Project\",\n        \"dockerComposeFile\": [ \"docker-compose.yml\", \"docker-compose.named-volume.yml\" ],\n```\n\nIn this case:\n- `/workspace` will become an empty **named volume**  in the `lamp` service\n- workspace files from the host will be mounted to the dir named `/source` in `lamp` container (dir not referenced by Apache)\n- `post-create-command.sh` will perform a *one-time* rsync from `/source` to `/workspace`.\n\nWith this setup you can work in the `/workspace` inside the container enjoying maximum performance. \nUsually you won't even need to sync files back to `/source`, because you can commit them to Git directly from the VSCode.\n\nHowever when you do need to keep files in sync between `/workspace` and `/source`, you can use Sync-Rsync VSCode extension \nthat comes pre-installed with this pattern (advanced users can use `rsync` from the command line).\n\n## Environment Variables\n\nIn `devcontainer.env` you can change Configuration Environment Variables ([see below](#configuration-environment-variables)) \nor add your custom environment variables to be passed to the `lamp` container. \nThis file is loaded as the env file in the `lamp` service inside its definition in `docker-compose.yml`.\n\n## Configuration Environment Variables\n\nThere are some predefined variables changing which in `devcontainer.env` will affect some aspects of the setup. \nUse them to quickly configure some things.\n\n### MYSQL_ROOT_PASSWORD\n\nSets MariaDB root password *during initial container creation*. \n\nIf you have already started container once and want to change it, then you would need to run `./rcm cleanup`. \nThis will remove all defied containers and their volumes. Then start devcontainer again. \nThis is required, because password would already be saved into `mysql` database. \nDatabase files are on a named volume, and named volumes are not removed during \"Remote-Containers: Rebuild container\".\n\n### XDEBUG_ENABLED\n\nSet to `1` to set [XDebug Mode](https://xdebug.org/docs/all_settings#mode) to `xdebug.mode=debug` (see `config/php/xdebug.ini`) \nthen run \"Remote-Containers: Rebuild container\". This can affect performance so turn back off when not needed.\n\n## Customize Container Configuration\n\nThere is automation in `post-create-command.sh` that copies properly named files from `config/...` directory to the container after its creation. \nThis allows to easily customize PHP and MariaDB/MySQL settings without fiddling with automation.\n\n### Customize PHP settings\n\nEdit `config/php/php.ini` then \"Remote-Containers: Rebuild container\" (affects both Apache and CLI versions).\n\n### Customize MariaDB/MySQL settings\n\nEdit `config/mysql/default.cnf` then \"Remote-Containers: Rebuild container\". \n\nNOTE: sometimes you will have to remove everything with `./rcm cleanup`, because settings can already be saved into `mysql` database. \nDatabase files are on a named volume, and named volumes are not removed during \"Remote-Containers: Rebuild container\".\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fachekulaev%2Frc-lde","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fachekulaev%2Frc-lde","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fachekulaev%2Frc-lde/lists"}