{"id":19075129,"url":"https://github.com/gremo/symfony-docker","last_synced_at":"2025-02-22T04:42:15.023Z","repository":{"id":255524905,"uuid":"852339652","full_name":"gremo/symfony-docker","owner":"gremo","description":"A simple archive that provides a development and production container for Symfony applications based on Docker","archived":false,"fork":false,"pushed_at":"2024-12-11T18:45:38.000Z","size":37,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-02T17:49:59.593Z","etag":null,"topics":["docker","frankenphp","php","symfony"],"latest_commit_sha":null,"homepage":"","language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"isc","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gremo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":".github/CONTRIBUTING.md","funding":".github/FUNDING.yaml","license":"LICENSE","code_of_conduct":".github/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":".github/SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"gremo"}},"created_at":"2024-09-04T16:29:46.000Z","updated_at":"2024-12-11T18:45:42.000Z","dependencies_parsed_at":"2024-12-11T15:28:18.554Z","dependency_job_id":"96e5bc26-9b4d-4da6-994c-20b45a582760","html_url":"https://github.com/gremo/symfony-docker","commit_stats":null,"previous_names":["gremo/symfony-docker"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gremo%2Fsymfony-docker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gremo%2Fsymfony-docker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gremo%2Fsymfony-docker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gremo%2Fsymfony-docker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gremo","download_url":"https://codeload.github.com/gremo/symfony-docker/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240127086,"owners_count":19751938,"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":["docker","frankenphp","php","symfony"],"created_at":"2024-11-09T01:53:28.198Z","updated_at":"2025-02-22T04:42:15.005Z","avatar_url":"https://github.com/gremo.png","language":"Dockerfile","readme":"# Symfony Docker\n\nA simple archive that provides a development and production container for Symfony applications based on Docker. Uses FrankenPHP, MariaDB, phpMyAdmin and Mailpit. Node.js is also supported and a basic Visual Studio Code customization is included.\n\n## ✨ Quick start\n\n1. Download the [**latest release**](https://github.com/gremo/symfony-docker/releases/download/latest/symfony-docker.zip) and unzip the archive.\n2. Open Visual Studio Code and **reopen the project in the Dev Container**.\n3. Download the **Symfony Skeleton**:\n    ```bash\n    curl -O https://raw.githubusercontent.com/symfony/skeleton/refs/heads/7.1/composer.json\n    ```\n4. Add Dev Container **extensions dependencies**:\n    ```bash\n    composer require --dev --no-update friendsofphp/php-cs-fixer phpstan/phpstan\n    ```\n5. If you plan to use **Docker in production**, add FrankenPHP runtime:\n    ```bash\n    composer require --no-update runtime/frankenphp-symfony\n    ```\n6. Install **Symfony**:\n    ```bash\n    composer install\n    ```\n\n\u003e [!IMPORTANT]\n\u003e PHPStan **will fail** if the `tests` folder is missing and you haven't installed either the `webapp` or `symfony/test-pack` packages. To resolve this, you can either install these packages or modify the `phpstan.dist.neon` configuration file.\n\n## ⚙️ Configuration\n\n\u003e [!NOTE]\n\u003e Composer version cannot be changed at the moment and is locked to the latest version.\n\nVarious versions can be set by changing the `compose.yaml` file:\n\n```yaml\n# compose.yaml\nservices:\n    php:\n        build:\n            args:\n                # Set the FrankenPHP version (default latest).\n                # Supports any FrankenPHP Docker tag.\n                FRANKENPHP_TAG: php8.3\n                # Set the Node.js version (default empty, meaning not installed).\n                # Supports a major version or keywords \"current\" and \"lts\".\n                NODE_VERSION: lts\n\n    db:\n        # Set the MariaDB version (default latest).\n        # Supports any MariaDB Docker tag.\n        image: mariadb:11\n\n    phpmyadmin:\n        # Set the phpMyAdmin version (default latest).\n        # Supports any phpMyAdmin Docker tag.\n        image: phpmyadmin:5\n```\n\nOther configuration files:\n\n- `config/docker/php*.ini` for PHP\n- `config/docker/supervisor.conf` for [Supervisor](http://supervisord.org/)\n\n## 🧑‍💻 Development tips\n\n\u003e [!NOTE]\n\u003e The `app` database is automatically created and can be accessed by the `app` user using the password `!ChangeMe!`. The same password is also assigned to the `root` user.\n\nAvailable endpoints are:\n\n| URL                                            | Service     |\n|------------------------------------------------|-------------|\n| [https://localhost](https://localhost)         | App         |\n| localhost:3306                                 | MariaDB     |\n| [http://localhost:8080](http://localhost:8080) | phpMyAdmin  |\n| [http://localhost:8025](http://localhost:8025) | Mailpit     |\n\nVisual Studio Code extensions installed and configured by default:\n\n- [PHP](https://marketplace.visualstudio.com/items?itemName=DEVSENSE.phptools-vscode)\n- [Git History](https://marketplace.visualstudio.com/items?itemName=donjayamanne.githistory)\n- [EditorConfig](https://marketplace.visualstudio.com/items?itemName=EditorConfig.EditorConfig)\n- [PHP CS Fixer](https://marketplace.visualstudio.com/items?itemName=junstyle.php-cs-fixer)\n- [DotENV](https://marketplace.visualstudio.com/items?itemName=mikestead.dotenv)\n- [PHPUnit Test Explorer](https://marketplace.visualstudio.com/items?itemName=recca0120.vscode-phpunit)\n- [JSON Schema Store Catalog](https://marketplace.visualstudio.com/items?itemName=remcohaszing.schemastore)\n- [PHPStan](https://marketplace.visualstudio.com/items?itemName=swordev.phpstan)\n\n## 🚀 Production tips\n\nCreate the `.env.prod.local` file to set up the environment for all containers:\n\n\u003e [!IMPORTANT]\n\u003e In production, all environment files are ignored except for `.env.prod.local`. The `.env` file will only be used to generate the `.env.local.php` file.\n\n```env\n# The domain name, HTTPS certificate is installed automatically\nSERVER_NAME=\"example.com\"\n\n# The timezone used by all containers\nTZ=\"Europe/Rome\"\n\n# Symfony container variables\nDATABASE_URL=\"mysql://$MARIADB_USER:$MARIADB_PASSWORD@db:3306/$MARIADB_DATABASE?charset=utf8\"\n\n# MariaDB container variables\nMARIADB_DATABASE=\"app\"\nMARIADB_USER=\"app\"\nMARIADB_PASSWORD=\"MySecretPassword\"\nMARIADB_ROOT_PASSWORD=\"MySecretRootPassword\"\n```\n\nTo run the project in production, execute `docker compose up -d`. FrankenPHP worker mode is enabled by default. Doctrine migrations are automatically executed if available.\n\n## ❤️ Contributing\n\nAll kinds of contributions are welcome and appreciated. See the [contributing](.github/CONTRIBUTING.md) guidelines, the community looks forward to your contributions!\n\n## 📘 License\n\nReleased under the terms of the [ISC License](LICENSE).\n","funding_links":["https://github.com/sponsors/gremo"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgremo%2Fsymfony-docker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgremo%2Fsymfony-docker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgremo%2Fsymfony-docker/lists"}