PHP 7 on AMI Linux (EC2)

You may also like...

  • How do I set it to be the default PHP used? when i do php -v, it still says 5.6.14 🙁

    • Jon Baker

      I think you’ll need to call it via php70 instead of just php

    • admin

      There is a seperate package for php70-cli, php70-cgi or php70-fpm – i’m just working on short update of this article

    • You just need to make sure, that you removed default php version. So do yum remove php php-common and so on, until you are clear and then install php70 version

      • Robert Lopez

        Can you elaborate more on how to actually remove this? You say “and so on”, what exactly is being deleted? The extensions?

        • sudo yum search php
          see what you got, and then remove all php (not 7.x) related modules.

  • Dwicandra

    Hi I am having trouble when installing php70-php-pecl-imagick, could you add instructions to also install imagick with php7 on AMI linux? thanks before

  • Timophey

    We have installed php-pecl-imagick from remi repo by enablling Base-Centos-6 repo(!!) and disabling amzn* repos during yum install. It works, but it is the very-very bad way. We want going to use ubuntu with php-7.0.