You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/installation.md
+75-12Lines changed: 75 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,19 +4,19 @@ title: Installation
4
4
5
5
## Overview
6
6
7
-
PhiloLogic5 runs as a Gunicorn WSGI applicationbehind a reverse proxy (Apache or Nginx). The installer handles Python, Node.js, and all Python dependencies automatically via [uv](https://docs.astral.sh/uv/).
7
+
PhiloLogic5 runs as a Gunicorn WSGI application. On Linux it typically runs behind a reverse proxy (Apache or Nginx); on macOS it can bind directly to a TCP port. The installer handles Python, Node.js, and all Python dependencies automatically via [uv](https://docs.astral.sh/uv/).
8
8
9
9
Installation steps:
10
10
11
11
1. Install system dependencies
12
12
2. Run `install.sh`
13
13
3. Configure `/etc/philologic/philologic5.cfg`
14
-
4. Set up your web server as a reverse proxy
14
+
4. Set up your web server as a reverse proxy (Linux) or configure a TCP port (macOS)
15
15
5. Enable and start the Gunicorn service
16
16
17
17
## System Requirements
18
18
19
-
- Linux (Ubuntu 22.04+, Debian 12+, RHEL 9+, or similar)
19
+
- Linux (Ubuntu 22.04+, Debian 12+, RHEL 9+, or similar) or macOS (Apple Silicon or Intel)
20
20
- Python 3.11+ (the installer downloads its own Python via uv by default)
21
21
- Root/sudo access for installing to `/var/lib/philologic5/`
22
22
@@ -39,11 +39,23 @@ sudo dnf install -y \
39
39
lz4 ripgrep curl
40
40
```
41
41
42
+
### macOS
43
+
44
+
```bash
45
+
brew install lz4 ripgrep
46
+
```
47
+
48
+
Xcode Command Line Tools are also required (for C compiler headers used by `lxml`):
49
+
50
+
```bash
51
+
xcode-select --install
52
+
```
53
+
42
54
**Notes:**
43
-
-`libxml2-dev`/`libxslt-dev`/`zlib1g-dev`: required for building `lxml` (XML parsing)
55
+
-`libxml2-dev`/`libxslt-dev`/`zlib1g-dev`: required for building `lxml` (XML parsing). On macOS these are provided by Xcode Command Line Tools.
44
56
-`liblz4-tool`/`lz4`: used at database load time for compressing word indexes
45
57
-`ripgrep`: used at database load time for filtering parser output
46
-
-`curl`: used by the installer to download [uv](https://docs.astral.sh/uv/) and [nvm](https://github.com/nvm-sh/nvm)
58
+
-`curl`: used by the installer to download [uv](https://docs.astral.sh/uv/) and [nvm](https://github.com/nvm-sh/nvm). Pre-installed on macOS.
47
59
- The installer downloads its own Python via uv, so system Python packages are not required
48
60
49
61
## Installing PhiloLogic
@@ -86,7 +98,7 @@ The installer:
86
98
7. Copies the web application to `/var/lib/philologic5/web_app/`
87
99
8. Installs the `philoload5` command to `/usr/local/bin/`
88
100
9. Creates the global config at `/etc/philologic/philologic5.cfg` (if it doesn't exist)
89
-
10. Installs a systemd service file for Gunicorn
101
+
10. Installs a systemd service file for Gunicorn (Linux) or a launchd plist (macOS)
PhiloLogic5 runs behind Gunicorn, which listens on a Unix socket. You need a reverse proxy (Apache or Nginx) to forward HTTP requests to Gunicorn.
155
+
### Linux
134
156
135
-
### Starting Gunicorn
157
+
On Linux, PhiloLogic5 runs behind Gunicorn, which listens on a Unix socket. You need a reverse proxy (Apache or Nginx) to forward HTTP requests to Gunicorn.
158
+
159
+
#### Starting Gunicorn
136
160
137
161
```bash
138
162
sudo systemctl enable philologic5-gunicorn
@@ -146,7 +170,42 @@ sudo systemctl status philologic5-gunicorn
On macOS, the simplest setup is to bind Gunicorn directly to a TCP port (no reverse proxy needed). Edit `/var/lib/philologic5/web_app/gunicorn.conf.py` and change the `bind` setting:
176
+
177
+
```python
178
+
bind ="127.0.0.1:8080"
179
+
```
180
+
181
+
Make sure the port matches the one in your `url_root` in `/etc/philologic/philologic5.cfg`.
On macOS, the simplest setup is to bind Gunicorn directly to a TCP port instead of a Unix socket. Edit `/var/lib/philologic5/web_app/gunicorn.conf.py` and change:
44
+
45
+
```python
46
+
bind ="127.0.0.1:8080"
47
+
```
48
+
49
+
Make sure the port matches the one in your `url_root` above. This customization is preserved across reinstalls.
0 commit comments