SOLVED Recover deleted nginx web files?

chravis

Contributor
Joined
Jan 27, 2019
Messages
104
So I'm a complete moron and deleted files that I should not have deleted.
I was creating a jail and installing nginx in it. I then used Filezilla to transfer some files and ended up in the wrong nginx www folder. I saw the subfolders and stupidly thought "oh these must be sample apps that get installed like when you install tomcat or something. I'll just delete these."
Turns out those are the webpages uses to run the TrueNAS gui screens. Woops! Does anyone know how I can get another copy of just that nginx stuff?
 

Kris Moore

SVP of Engineering
Administrator
Moderator
iXsystems
Joined
Nov 12, 2015
Messages
1,471
Thats tricky. You almost need to do do an upgrade / install again to make sure you get an intact installation setup properly. Otherwise you're stuck trying to read tarballs and extract that way, which could be a recipe for disaster if not handled perfectly.
 

chravis

Contributor
Joined
Jan 27, 2019
Messages
104
Would anyone be interested in zipping up there nginx directories and sending them to me?
I'm actually not positive where they all are but I think it would be /usr/local/www and /etc/local/nginx
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
It'd be much simpler, safer, and likely faster to do what Kris suggests--boot from a TrueNAS installer, install to your current boot device(s), and when asked tell it to do an upgrade.
 

chravis

Contributor
Joined
Jan 27, 2019
Messages
104
Thanks guys. That sounds like a good plan. I'll try it tomorrow and see what happens.
 

chravis

Contributor
Joined
Jan 27, 2019
Messages
104
you guys are genius and saved my bacon. Thank you so much for the help. All is well. Won't make that mistake again.
 
Top