Run PHP Mess Detector (phpmd) in Docker container
Build from Dockerfile:
docker build -t fredericomartini/phpmd .Verify build:
docker run --rm -it fredericomartini/phpmd --version- Install the
fredericomartini/phpmdcontainer (optional - this step is performed by Docker automatically when running the container):
$ docker pull fredericomartini/phpmd- Define an bash alias that runs this container whenever
phpmdis invoked on the command line:
$ echo "alias phpmd='docker run --rm -it -v \$(pwd):/app fredericomartini/phpmd'" >> ~/.bashrc
$ source ~/.bashrc- Run phpmd as always:
$ phpmd --version