forked from e621ng/e621ng
[Vagrant] Allow remote postgres connections
This makes it easiliy possible to use a local client to take a look into the database
This commit is contained in:
parent
e595e1de99
commit
69869a2d62
@ -21,6 +21,10 @@ By the time you get back the install will surely have completed.<sup>1</sup>
|
|||||||
|
|
||||||
<sub><sup>1</sup> If the install did not finish by the time an activity is complete please select another activity to avoid crippling boredom.</sub>
|
<sub><sup>1</sup> If the install did not finish by the time an activity is complete please select another activity to avoid crippling boredom.</sub>
|
||||||
|
|
||||||
|
#### Development Database
|
||||||
|
|
||||||
|
The postgres server accepts outside connections which you can use to connect with a local client. Use `192.168.64.78:5432` to connect to a database named `danbooru2` with the user `danbooru`. Leave the password blank, anything will work.
|
||||||
|
|
||||||
#### VirtualBox Troubleshooting
|
#### VirtualBox Troubleshooting
|
||||||
|
|
||||||
In case the VM doesn't start with the error `VT-x not available` and the error description `WHvCapabilityCodeHypervisorPresent is FALSE!` the the following solution should resolve the issue:
|
In case the VM doesn't start with the error `VT-x not available` and the error description `WHvCapabilityCodeHypervisorPresent is FALSE!` the the following solution should resolve the issue:
|
||||||
|
@ -88,7 +88,14 @@ systemctl enable elasticsearch 2>/dev/null
|
|||||||
service elasticsearch start
|
service elasticsearch start
|
||||||
|
|
||||||
script_log "Setting up postgres..."
|
script_log "Setting up postgres..."
|
||||||
|
# allow connections from the host machine
|
||||||
|
if ! grep -q "192" "/etc/postgresql/12/main/pg_hba.conf"; then
|
||||||
|
echo "host danbooru2,danbooru2_test danbooru 192.168.64.1/32 trust" >> /etc/postgresql/12/main/pg_hba.conf
|
||||||
|
fi
|
||||||
|
# do not require passwords for authentication
|
||||||
sed -i -e 's/md5/trust/' /etc/postgresql/12/main/pg_hba.conf
|
sed -i -e 's/md5/trust/' /etc/postgresql/12/main/pg_hba.conf
|
||||||
|
# listen for outside connections
|
||||||
|
echo "listen_addresses = '*'" > /etc/postgresql/12/main/conf.d/listen_addresses.conf
|
||||||
|
|
||||||
if [ ! -f /usr/lib/postgresql/12/lib/test_parser.so ]; then
|
if [ ! -f /usr/lib/postgresql/12/lib/test_parser.so ]; then
|
||||||
script_log "Building test_parser..."
|
script_log "Building test_parser..."
|
||||||
|
Loading…
Reference in New Issue
Block a user