I just deployed a Digital Ocean droplet and I think it was hacked within 20 minutes of deploying. Basically, I built Nginx from source the only added extra's I installed (outside the dependencies) were mod_pagespeed from GitHub (https://github.com/apache/incubator-pagespeed-ngx/archive/v${NPS_VERSION}.tar.gz).
I noticed rather quickly as I couldn't start nginx due to the port being in use and noticed some very strange logs for a new droplet.
When visiting the website listed in these logs below, the default nginx page was displayed. I tried checking the dns records for the domain but it's using Cloudflare. Now since destroying and rebuilding the droplet, the website is down, so it looks like this site was definitely loading from my server. Does anyone have any insight as to what might have happened? Was it hacked? Or was this a resused IP or something, if hacked , how to prevent this happening again?
2021/05/05 08:54:50 [error] 49585#49585: *13 open() "/usr/local/nginx/html/breakingNews/newsDetails/12887/SEE-WHAT-FIRST-LADY-DID-TO-KUMUYI---PHOTOS" failed (2: No such file or directory), client: 162.158.159.133, server: localhost, request: "GET /breakingNews/newsDetails/12887/SEE-WHAT-FIRST-LADY-DID-TO-KUMUYI---PHOTOS HTTP/1.1", host: "ogbongefriends.com"
2021/05/05 08:59:10 [error] 49585#49585: *14 open() "/usr/local/nginx/html/userdata/news_media/SE0b5iQjWpCdz9y17IVs.jpg" failed (2: No such file or directory), client: 141.101.99.44, server: localhost, request: "GET /userdata/news_media/SE0b5iQjWpCdz9y17IVs.jpg HTTP/1.1", host: "www.ogbongefriends.com", referrer: "http://www.ogbongefriends.com/breakingNews/newsDetails/7648/NAKED-NIGERIAN-GIRLS-STORM-A-NIGHT-CLUB-IN-LAGOS-PHOTOS"
2021/05/05 09:14:25 [error] 49585#49585: *15 open() "/usr/local/nginx/html/breakingNews/newsDetails/13376/NINE-BLACK-AMERICANS-SHOT-BY-US-POLICE" failed (2: No such file or directory), client: 141.101.98.147, server: localhost, request: "GET /breakingNews/newsDetails/13376/NINE-BLACK-AMERICANS-SHOT-BY-US-POLICE HTTP/1.1", host: "ogbongefriends.com"
2021/05/05 09:27:15 [error] 49585#49585: *17 open() "/usr/local/nginx/html/userdata/news_media/gVCbr935Om2fnWo4zhLS.jpg" failed (2: No such file or directory), client: 141.101.99.238, server: localhost, request: "GET /userdata/news_media/gVCbr935Om2fnWo4zhLS.jpg HTTP/1.1", host: "www.ogbongefriends.com"
2021/05/05 09:29:25 [error] 49585#49585: *18 open() "/usr/local/nginx/html/config/getuser" failed (2: No such file or directory), client: 205.185.122.102, server: localhost, request: "GET /config/getuser?index=0 HTTP/1.1", host: "188.166.156.235:80"