devcontainer.json 1.1 KB

1234567891011121314151617181920212223242526272829
  1. // For format details, see https://aka.ms/devcontainer.json. For config options, see the
  2. // README at: https://github.com/devcontainers/templates/tree/main/src/php-mariadb
  3. {
  4. "name": "${localWorkspaceFolderBasename}",
  5. "dockerComposeFile": "./docker-compose.yml",
  6. "service": "web",
  7. "workspaceFolder": "/var/www/html",
  8. // Features to add to the dev container. More info: https://containers.dev/features.
  9. // "features": {},
  10. // For use with PHP or Apache (e.g.php -S localhost:8080 or apache2ctl start)
  11. "forwardPorts": [],
  12. // Use 'postCreateCommand' to run commands after the container is created.
  13. "postCreateCommand": "php artisan migrate --force && php artisan db:seed",
  14. "postStartCommand": "git config --global --add safe.directory /var/www/html && npm install && composer install && npm run build && apachectl start",
  15. // Configure tool-specific properties.
  16. "customizations" : {
  17. "jetbrains" : {
  18. "backend" : "PhpStorm"
  19. }
  20. },
  21. // Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
  22. "remoteUser": "root"
  23. }