Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gremo/symfony-sail
An easy to use Docker development and production environment for Symfony 4/5/6 projects, zero-config and fully customizable.
https://github.com/gremo/symfony-sail
containers devcontainer docker php symfony vscode
Last synced: about 2 months ago
JSON representation
An easy to use Docker development and production environment for Symfony 4/5/6 projects, zero-config and fully customizable.
- Host: GitHub
- URL: https://github.com/gremo/symfony-sail
- Owner: gremo
- License: isc
- Created: 2023-03-26T01:39:04.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-01-24T09:12:32.000Z (11 months ago)
- Last Synced: 2024-01-24T18:54:16.374Z (11 months ago)
- Topics: containers, devcontainer, docker, php, symfony, vscode
- Language: Dockerfile
- Homepage:
- Size: 107 KB
- Stars: 29
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Security: SECURITY.md
Awesome Lists containing this project
README
Symfony Sail
An easy to use Docker development and production environment for Symfony 4/5/6 projects, zero-config yet fully customizable.
Key features •
Quick start •
Documentation •
Contributing •
LicenseThis project is inspired by [dunglas/symfony-docker](https://github.com/dunglas/symfony-docker), but it aims to be more **customizable** (while remaining **zero-config**) and enhance the **developer experience**. It includes support for Visual Studio Code **Dev Containers**, **MariaDB** and **Webpack Encore/Vite**.
> **Warning**: this project is still under development, please use it for testing purposes and feel free to suggest changes and improvements.
## 💫 Key features
- ✅ Zero-config yet fully customizable
- ✅ Use the `.env.local` file you are already familiar with
- ✅ Visual Studio Code [dev container](https://code.visualstudio.com/docs/devcontainers/containers), opinionated settings and extensions
- ✅ [MariaDB](https://mariadb.com/products/community-server), automatic Doctrine `DATABASE_URL` parsing, migrations support
- ✅ [Caddy](https://caddyserver.com) web server, automatic HTTPS and www to non-www redirection, HTTP/2, [Vulcain](https://vulcain.rocks) support
- ✅ [Webpack Encore](https://github.com/symfony/webpack-encore) and [Vite](https://github.com/vitejs/vite) support
- ✅ PHP OPcache [preloading](https://www.php.net/manual/en/opcache.preloading.php) support
- ✅ Docker pre-built multi-platform images for faster startupVersions without database, production configuration and Visual Studio Code settings and extensions are also available!
## ⚡ Quick start
The only requirements are [Docker Desktop](https://www.docker.com/products/docker-desktop) and [Visual Studio Code](https://code.visualstudio.com) with the [Dev Containers extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) installed.
👇 Grab the latest release! 👇
> **Warning**: use release links and **DO NOT clone** this repository and use it directly as it is not intended to be used that way.
| Release | Database | Production configuration | VSCode configuration |
| :---------------------------------------------------------------------------------------------------------- | :------: | :----------------------: | :------------------: |
| [symfony-sail.zip](https://github.com/gremo/symfony-sail/releases/latest/download/symfony-sail.zip) | ✅ | ✅ | ✅ |
| [symfony-sail-v.zip](https://github.com/gremo/symfony-sail/releases/latest/download/symfony-sail-v.zip) | ✅ | ✅ | ❌ |
| [symfony-sail-p.zip](https://github.com/gremo/symfony-sail/releases/latest/download/symfony-sail-p.zip) | ✅ | ❌ | ✅ |
| [symfony-sail-pv.zip](https://github.com/gremo/symfony-sail/releases/latest/download/symfony-sail-pv.zip) | ✅ | ❌ | ❌ |
| [symfony-sail-d.zip](https://github.com/gremo/symfony-sail/releases/latest/download/symfony-sail-d.zip) | ❌ | ✅ | ✅ |
| [symfony-sail-dv.zip](https://github.com/gremo/symfony-sail/releases/latest/download/symfony-sail-dv.zip) | ❌ | ✅ | ❌ |
| [symfony-sail-dp.zip](https://github.com/gremo/symfony-sail/releases/latest/download/symfony-sail-dp.zip) | ❌ | ❌ | ✅ |
| [symfony-sail-dpv.zip](https://github.com/gremo/symfony-sail/releases/latest/download/symfony-sail-dpv.zip) | ❌ | ❌ | ❌ |Want to start developing a **brand-new Symfony project**?
> **Note**: during development, leaving an empty `DATABASE_URL` in `.env.local` means passwordless root access.
1. Extract the archive into a new folder
2. Create an empty `.env.local` file and [configure the environment](docs/configuration.md)
3. Open the project in the Dev Container
4. Execute `curl -O https://raw.githubusercontent.com/symfony/skeleton/6.3/composer.json`
5. Execute `composer install` and optionally `composer require webapp`
6. Proceed [configuring Visual Studio Code](docs/configuring-vscode.md)If you want to dockerize your **existing project**:
> **Note**: make sure your existing `DATABASE_URL` in `.env.local` both "mysql://" and "db:3306".
1. Extract the archive into the project's root folder
2. **Double-check for any overwritten files**
3. Edit your existing `.env.local` file and [configure the environment](docs/configuration.md)
4. Open the project in the Dev Container
5. Proceed [configuring Visual Studio Code](docs/configuring-vscode.md)Your website is already available at [http://localhost](http://localhost) 🎉
## 📖 Documentation
- [Configuration](docs/configuration.md)
- [FAQ](docs/faq.md)
- [Configuring Visual Studio Code](docs/configuring-vscode.md)
- [Going to production](docs/production.md)## ❤️ Contributing
All types of contributions are encouraged and valued. See the [contributing](CONTRIBUTING.md) guidelines, the community looks forward to your contributions!
## 📘 License
Symfony Sail is released under the terms of the [ISC License](LICENSE).