UnamSanctam / UnamWebPanel

MIT License
175 stars 58 forks source link

Getting "Error: Something went wrong." In login page #235

Closed queider closed 1 year ago

queider commented 1 year ago

I tried setting the panel on a vps. First I installed xampp and putted the content of the UnamWebPanel in the htdocs then fired it up. Anything I'm doign wrong? Thank you.

UnamSanctam commented 1 year ago

Can you find any error.log files anywhere? Or any log files inside the __UNAM_LIB\Logs\ folder?

queider commented 1 year ago

didn't find any log files. Maybe some PHP libs are missing?

UnamSanctam commented 1 year ago

Shouldn't be, it should work right away with XAMPP without any changes. You didn't accidentally change something you shouldn't in the config.php file or anything? And you're using the latest XAMPP correct?

queider commented 1 year ago

Yes just used the XAMPP as is. Didn't even changed the password or anything. I'm using an ubuntu vps server. When I tried to local test it on my windows machine with XAMPP it worked perfectly.

UnamSanctam commented 1 year ago

Oh, you're using XAMPP on Linux? I've never tested XAMPP on Linux since setting up Apache and PHP manually is easier than XAMPP (in my opinion), but I would strongly guess it's some form of permission issue for the files.

queider commented 1 year ago

Do I jast install apache and php? Do I need anything else?

UnamSanctam commented 1 year ago

Yes it's very easy, you could follow https://www.digitalocean.com/community/tutorials/how-to-install-the-apache-web-server-on-ubuntu-22-04. Step 5 of that guide isn't required though doing that could be good.

queider commented 1 year ago

Thank you just fixed it. I installed xampp and chmod 777 htdocs/* and it worked. But for some reason when i tested a miner configuration it didn't appear on the panel...

UnamSanctam commented 1 year ago

Alright, you could probably also set it to 755 as long as the files are owned by the correct user. Make sure that you're using the correct http or https depending on if you have a certificate or not.

queider commented 1 year ago

Failed to open stream: Permission denied in /opt/lampp/htdocs/__UNAM_LIB/unam_lib.php on line 235 I found this in the error.log in the api folder. Maybe that's the reason the api didn't work? What should I do?

UnamSanctam commented 1 year ago

Make sure that both the db folder and the unamwebpanel.db file inside it has the permissions as well. And make sure that your Apache user (www-data usually from what I remember) owns all the folders.

queider commented 1 year ago

I gave permissions and it worked! Thanks man your awesome