-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathplaybook.lampserver.yml
More file actions
72 lines (49 loc) · 1.26 KB
/
Copy pathplaybook.lampserver.yml
File metadata and controls
72 lines (49 loc) · 1.26 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
---
- hosts: asusvpn
become: true
tasks:
- name: Update apt cache if needed.
apt: update_cache=yes cache_valid_time=3600
- name: Get software for apt repository management.
apt: name={{ item }} state=present
with_items:
- python-apt
- python-pycurl
- name: Add ondrej repository for later versions of PHP.
apt_repository: repo='ppa:ondrej/php5' update_cache=yes
- name: "Install Apache, MySQL, PHP, and other dependencies."
apt: name={{ item }} state=present
with_items:
- git
- curl
- sendmail
- apache2
- php5
- php5-common
- php5-mysql
- php5-cli
- php5-curl
- php5-gd
- php5-dev
- php5-mcrypt
- php-apc
- php-pear
- python-mysqldb
- mysql-server
- name: "Start Apache, MySQL, and PHP."
service: "name={{ item }} state=started enabled=yes"
with_items:
- apache2
- mysql
- name: Enable Apache rewrite module
apache2_module: name=rewrite state=present
notify: restart apache
- name: Remove default virtualhost file.
file:
path: "/etc/apache2/sites-enabled/000-default"
state: absent
notify: restart apache
- name: Remove the MySQL test database.
mysql_db: db=test state=absent
- name: Create a database for kevwells
mysql_db: "db={{ domain }} state=present"