Skip to content
  • Fergus Whyte's avatar
    Bug 1955620: Adding options for development in PHP 7.4, 8, and 8.1 for Docker setup · 7bfda980
    Fergus Whyte authored and Robert Lyon's avatar Robert Lyon committed
    tl;dr;
    
    * Focal added for PHP7.4
    * XDebug working in Focal
    * Jammy added for PHP8.1
    
    ---
    
    Added Focal for PHP 7.4.  This is the minimum version of PHP needed for
    Behat tests.
    
    To use Focal set DOCKER_PHP_MAJOR_VERSION in the shell you are working
    in.
    
    export DOCKER_PHP_MAJOR_VERSION=7.4
    
    XDebug is now available for Focal on port 9000. For VSCode configure
    your launch.json file with path mapping set to the path inside the
    container.
    
    i.e.
    {
      "version": "0.2.0",
      "configurations": [
        {
          "name": "Listen for XDebug in Docker",
          "type": "php",
          "request": "launch",
          "port": 9000,
          "pathMappings": {
              "/mahara/": "${workspaceFolder}/",
           },
           "log": true
        }
      ]
    }
    
    XDebug is also working for scripts running on the CLI inside
    the container.
    
    Added Jammy for PHP 8.1.  This is the minimum version of PHP needed for
    Behat tests.
    
    To use Focal set DOCKER_PHP_MAJOR_VERSION in the shell ...
    7bfda980