Situation
The orders site app.lab.test and its PostgreSQL database used to live on one machine, node2. The
site has moved to node1: nginx with HTTPS and the application, the lab-shop service, now run
there. The shop database stayed on node2. Since the move, curl https://app.lab.test/ on node1
answers with an error instead of the order list.
node1 is your terminal. Run commands on node2 over SSH: ssh node2 'command', or enter its shell
with ssh node2 and come back with exit. sudo works without a password on both machines. There is
no other way into node2, so don't lock yourself out of SSH.
Task
curl https://app.lab.test/on node1 gets HTTP 200 and the order list from the database on node2.- The
shoprole logs in to the database from node1 with its password, and with a wrong password neithershopnorpostgrescan log in from node1. - Port
5432on node2 is open to node1 and closed to other addresses on the network, and stays so after node2 reboots.
The lab has no internet access, only the network between node1 and node2. Everything you need is installed on both machines.
Lab goals
0 of 3-
curl https://app.lab.test/ on node1 gets 200 and the order list from the database on node2 — not checked yet
-
From node1 the shop role logs in with its password, and with a wrong password neither shop nor postgres gets in — not checked yet
-
Port 5432 on node2 is open to node1 and closed to other addresses on the network — after a node2 reboot too — not checked yet
Hints
0 of 3 open · they open one at a time
Hint 1
Show the solution
after 3 failed checks