32 lines
805 B
Markdown
32 lines
805 B
Markdown
https://github.com/ankane/pghero/blob/master/guides/Linux.md
|
||
|
||
get:
|
||
```
|
||
wget -qO- https://dl.packager.io/srv/pghero/pghero/key | sudo apt-key add -
|
||
sudo wget -O /etc/apt/sources.list.d/pghero.list \
|
||
https://dl.packager.io/srv/pghero/pghero/master/installer/ubuntu/18.04.repo
|
||
sudo apt-get update
|
||
sudo apt-get -y install pghero
|
||
```
|
||
|
||
Add your database. (use \ to escape special passw chars)
|
||
```
|
||
sudo pghero config:set DATABASE_URL=postgres://user:password@hostname:5432/dbname
|
||
```
|
||
|
||
And optional authentication.
|
||
```
|
||
sudo pghero config:set PGHERO_USERNAME=link
|
||
sudo pghero config:set PGHERO_PASSWORD=hyrule
|
||
```
|
||
|
||
Start the server
|
||
```
|
||
sudo pghero config:set PORT=3001
|
||
sudo pghero config:set RAILS_LOG_TO_STDOUT=disabled
|
||
sudo pghero scale web=1
|
||
```
|
||
|
||
Confirm it’s running with:
|
||
|
||
`curl -v http://localhost:3001/` |