Skip to content

Commit 66e5c8d

Browse files
authored
Merge pull request #33 from dirkaholic/feature/php7
Set php default version to 7.0, upgrade Ubuntu to 16.04
2 parents a5e7190 + 38fe109 commit 66e5c8d

File tree

8 files changed

+28
-15
lines changed

8 files changed

+28
-15
lines changed

Readme.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,18 +31,24 @@ Installed components
3131

3232
* [Nginx](http://nginx.org)
3333
* [MySQL](http://dev.mysql.com/downloads/mysql/)
34-
* [PHP 5.6](http://www.php.net/)
34+
* [PHP 7.0](http://www.php.net/)
3535
* [php-fpm](http://php-fpm.org)
3636
* [git](http://git-scm.com/)
3737
* [Composer](https://getcomposer.org/)
3838
* [Symfony2 Standard Edition](https://github.com/symfony/symfony-standard)
3939
* [Laravel](https://laravel.com/)
4040
* [PHPUnit](https://phpunit.de/)
4141

42+
If you don't like/need some of the components just remove them from the roles section in playbook/vagrant.yml.
43+
4244
Changes
4345
-------
4446

4547
### unreleased
48+
49+
* Introduce php_version variable, set PHP default version to 7.0 [#33](https://github.com/dirkaholic/vagrant-php-dev-box/pull/33)
50+
* Upgrade Ubuntu box to 16.04 (latest LTS version) [#33](https://github.com/dirkaholic/vagrant-php-dev-box/pull/33)
51+
4652
### v1.4.0
4753

4854
* Transfer ansible playbooks to roles [#31](https://github.com/dirkaholic/vagrant-php-dev-box/pull/31)

Vagrantfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Vagrant.require_version ">= 1.7.0"
33

44
Vagrant.configure(2) do |config|
55

6-
config.vm.box = "ubuntu/trusty64"
6+
config.vm.box = "bento/ubuntu-16.04"
77

88
# Disable the new default behavior introduced in Vagrant 1.7, to
99
# ensure that all Vagrant machines will use the same SSH key pair.

playbooks/roles/laravel-quickstart/tasks/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
- name: Copy across new php-fpm pool config for laravel
3838
template:
3939
src=php-fpm.conf.j2
40-
dest=/etc/php/5.6/fpm/pool.d/laravel.conf
40+
dest=/etc/php/{{ php_version }}/fpm/pool.d/laravel.conf
4141
notify:
4242
- restart php-fpm
4343

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
- name: restart php-fpm
2-
service: name=php5.6-fpm state=restarted
2+
service: name=php{{ php_version }}-fpm state=restarted
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
---
22
- name: Install php-fpm
3-
apt: name=php5.6-fpm state=present
3+
apt: name=php{{ php_version }}-fpm state=present

playbooks/roles/php/defaults/main.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
---
2+
php_version: 7.0
23
composer_process_timeout: 900

playbooks/roles/php/tasks/main.yml

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,28 @@
11
---
2-
- name: Add apt repository for PHP 5.6
2+
- name: Add apt key for PHP ppa
3+
apt_key:
4+
keyserver: keyserver.ubuntu.com
5+
id: 14AA40EC0831756756D7F66C4F4EA0AAE5267A6C
6+
state: present
7+
8+
- name: Add apt repository for PHP
39
apt_repository: repo='ppa:ondrej/php/ubuntu'
410

511
- name: Install python-software-properties
612
apt: name=python-software-properties state=present
713

8-
- name: Install php 5.6
9-
apt: name=php5.6 state=present
14+
- name: Install PHP
15+
apt: name=php{{ php_version }} state=present
1016

1117
- name: Install required php packages
1218
apt: name={{ item }} state=present
1319
with_items:
14-
- php5.6-mysql
15-
- php5.6-intl
16-
- php5.6-cli
17-
- php5.6-mcrypt
18-
- php5.6-mbstring
19-
- php5.6-dom
20+
- php{{ php_version }}-mysql
21+
- php{{ php_version }}-intl
22+
- php{{ php_version }}-cli
23+
- php{{ php_version }}-mcrypt
24+
- php{{ php_version }}-mbstring
25+
- php{{ php_version }}-dom
2026

2127
- name: Enable the MCrypt extension
2228
shell: phpenmod mcrypt

playbooks/roles/symfony-standard/tasks/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
- name: Copy across new php-fpm pool config for symfony
2828
template:
2929
src=php-fpm.conf.j2
30-
dest=/etc/php/5.6/fpm/pool.d/symfony.conf
30+
dest=/etc/php/{{ php_version }}/fpm/pool.d/symfony.conf
3131
notify:
3232
- restart php-fpm
3333

0 commit comments

Comments
 (0)