Skip to content

Commit ad8c60d

Browse files
committed
Modernize README with better install steps
1 parent 30ffd6c commit ad8c60d

File tree

1 file changed

+67
-32
lines changed

1 file changed

+67
-32
lines changed

README.md

Lines changed: 67 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
# BNETDocs: Phoenix
1+
# BNETDocs
22

33
[![Build Status](https://travis-ci.org/BNETDocs/bnetdocs-web.svg?branch=phoenix)](https://travis-ci.org/BNETDocs/bnetdocs-web)
44

5-
## Preface
65
BNETDocs is a web content management system (CMS) and documentation software
76
for the Battle.net™ online gaming service's protocol. It provides a means
87
for documenting the protocol and encouraging discussion on it.
@@ -21,34 +20,70 @@ the root of this repository for more info.
2120

2221
## Installation
2322

24-
1. Clone this repository to a local directory on your development environment.
25-
- Recommended location: `/home/nginx/bnetdocs-local/`
26-
2. Setup an nginx/php-fpm web server using
27-
[nginx-conf](https://github.com/carlbennett/nginx-conf) as the config.
28-
3. Copy the `/etc/nginx-vhost-sample.conf` file to your local nginx.
29-
- Recommended location: `/etc/nginx/sites-available/local.bnetdocs.org.conf`
30-
4. Create a symbolic link from
31-
`/etc/nginx/sites-available/local.bnetdocs.org.conf` to
32-
`/etc/nginx/sites-enabled/local.bnetdocs.org.conf`.
33-
5. Reconfigure your `local.bnetdocs.org.conf` file as necessary to work with
34-
your environment. You will need to modify the `server_name` directives and
35-
even quite possibly remove some `server` blocks.
36-
6. Install additional php modules:
37-
- php-gmp
38-
- php-mbstring
39-
- php-mcrypt
40-
- php-memcache
41-
- php-memcached
42-
- php-mysqlnd
43-
- php-pdo
44-
- php-pecl-geoip
45-
- php-pecl-http
46-
- php-pecl-jsonc
47-
7. Start nginx and php-fpm on your server and ensure they begin running.
48-
8. Import and setup the sample database.
49-
9. Copy `/etc/config.sample.json` to `/etc/config.phoenix.json` and modify it
50-
to your environment.
51-
10. Try accessing this endpoint:
52-
[local.bnetdocs.org](https://local.bnetdocs.org)
53-
- You may need to modify your `/etc/hosts` file if your development
23+
### Clone this repository
24+
```sh
25+
cd ~
26+
git clone git@github.com:BNETDocs/bnetdocs-web.git
27+
```
28+
29+
### Install nginx
30+
Follow the guide available over at
31+
[carlbennett/nginx-conf](https://github.com/carlbennett/nginx-conf).
32+
33+
After successfully installing **carlbennett/nginx-conf**, run:
34+
35+
```sh
36+
sudo cp ./etc/nginx-vhost-sample.conf \
37+
/etc/nginx/sites-available/local.bnetdocs.org.conf
38+
sudo ln -s \
39+
/etc/nginx/sites-available/local.bnetdocs.org.conf \
40+
/etc/nginx/sites-enabled/
41+
```
42+
43+
After running the above, modify the new file to your liking. It's recommended
44+
to update the `server_name` directives to `local.bnetdocs.org`. Please look
45+
over the file and perform any updates to it as you see fit.
46+
47+
### Install php-fpm
48+
#### CentOS 7.x / Fedora 24
49+
```sh
50+
sudo yum install php-fpm
51+
```
52+
53+
#### Debian / Ubuntu
54+
```sh
55+
sudo apt-get update && sudo apt-get install php-fpm
56+
```
57+
58+
### Satisfy composer
59+
Run `composer install` at the root of the repository.
60+
61+
### Run nginx and php-fpm
62+
#### CentOS 7.x / Fedora 24
63+
```sh
64+
sudo systemctl start nginx php-fpm
65+
```
66+
67+
#### Debian / Ubuntu
68+
```sh
69+
sudo /etc/init.d/nginx start && sudo /etc/init.d/php-fpm start
70+
```
71+
72+
### Import sample database
73+
```sh
74+
mysql < ./etc/database.sample.sql
75+
```
76+
77+
### Configure BNETDocs
78+
```sh
79+
cp ./etc/config.sample.json ./etc/config.phoenix.json
80+
```
81+
82+
\* Open `config.phoenix.json` in your favorite text editor and modify it to
83+
your liking.
84+
85+
### Test
86+
Try accessing this endpoint: [local.bnetdocs.org](https://local.bnetdocs.org)
87+
88+
\* You may need to modify your `/etc/hosts` file if your development
5489
environment is not your localhost.

0 commit comments

Comments
 (0)