PHP Classes

Docker Symfony App: Symfony project to deploy using Docker

Recommend this page to a friend!
     
  Info   Example   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 14 All time: 11,441 This week: 47Up
Version License PHP version Categories
symfony_app 1.0GNU General Publi...5PHP 5, Systems administration, Libraries
Description 

Author

This package Symfony project to deploy using Docker.

It provides configuration PHP scripts and classes to deploy a Symfony application using a Docker container.

The package supports the configuration to run the application using PHP 8.1, Symfony 6, Nginx, and debugging with XDebug.

Picture of Max Stemplevski
  Performance   Level  
Innovation award
Innovation award
Nominee: 5x

 

Example

<?php

use App\Kernel;

require_once
dirname(__DIR__).'/vendor/autoload_runtime.php';

return function (array
$context) {
    return new
Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
};


Details

Symfony Application - symfony_app

  • Composer - version 2.4.4
  • Nginx version: nginx/1.18.0 (Ubuntu)
  • Symfony version: 6.1
  • PHP: 8.1

Docker part (installation and configuration)

Usefull commands for this part (Most of these in Makefile):

- id $USER; sudo chown -R www-data:www-data /var/log/nginx; sudo chmod -R 755 /var/log/nginx; - docker-compose -f ./docker/docker-compose.yml build - docker-compose -f ./docker/docker-compose.yml up - docker-compose -f ./docker/docker-compose.yml --env-file ./docker/.env exec -u www-data php-fpm bash - composer create-project symfony/skeleton:"6.1.*" my_project_directory

Debugging

Usefull commands:

  • make dc_stop dc_build dc_up
  • make app_bash
  • php -m
  • make check

  Files folder image Files (29)  
File Role Description
Files folder image.idea (4 files, 1 directory)
Files folder imagebin (1 file)
Files folder imageconfig (4 files, 2 directories)
Files folder imagedocker (2 files, 2 directories)
Files folder imagepublic (1 file)
Files folder imagesrc (1 file)
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file composer.lock Data Auxiliary data
Accessible without login Plain text file Makefile Data Auxiliary data
Accessible without login Plain text file README.md Doc. Documentation
Accessible without login Plain text file symfony.lock Data Auxiliary data

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:14
This week:0
All time:11,441
This week:47Up