Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot get bookstack to load - Manual install #5050

Closed
2 tasks done
Jeffrey-FB opened this issue Jun 4, 2024 · 4 comments
Closed
2 tasks done

Cannot get bookstack to load - Manual install #5050

Jeffrey-FB opened this issue Jun 4, 2024 · 4 comments

Comments

@Jeffrey-FB
Copy link

Jeffrey-FB commented Jun 4, 2024

Attempted Debugging

  • I have read the debugging page

Searched GitHub Issues

  • I have searched GitHub for the issue.

Describe the Scenario

Really not sure where i have gone wrong here.
I've tried to setup bookstack with a existing database in AWS.
Database side of it looks all good.

I'm at the point where I'm trying to get a page.
but i get nothing.
I've tried repairing the permissions with not change.

Not sure what I'm missing happy to try anything?
even is there is an easy way to put my database info into a fresh install script.
i.e. [https://github.com/BookStackApp/devops/blob/main/scripts/installation-ubuntu-24.04.sh]

Exact BookStack Version

24.05.1

Log Content

Details

:/home/ubuntu# tail /var/log/nginx/bookstack.error.log
#2 /var/www/BookStack/vendor/monolog/monolog/src/Monolog/Logger.php(644): Monolog\Logger->addRecord()
#3 /var/www/BookStack/vendor/laravel/framework/src/Illuminate/Log/Logger.php(184): Monolog\Logger->error()
#4 /var/www/Boo...; PHP message: PHP Fatal error:  Uncaught UnexpectedValueException: The stream or file "/var/www/BookStack/storage/logs/laravel.log" could not be opened in append mode: Failed to open stream: Permission denied
The exception occurred while attempting to log: file_put_contents(/var/www/BookStack/storage/framework/views/019b63655f0602243bf3829336bebd7f.php): Failed to open stream: Permission denied
Context: {"exception":{}} in /var/www/BookStack/vendor/monolog/monolog/src/Monolog/Handler/StreamHandler.php:137
Stack trace:
#0 /var/www/BookStack/vendor/monolog/monolog/src/Monolog/Handler/AbstractProcessingHandler.php(44): Monolog\Handler\StreamHandler->write()
#1 /var/www/BookStack/vendor/monolog/monolog/src/Monolog/Logger.php(389): Monolog\Handler\AbstractProcessingHandler->handle()
#2 /var/www/BookStack/vendor/monolog/monolog/src/Monolog/Logger.php(644): Monolog\Logger->addRecord()
#3 /var/www/BookStack/vendor/laravel/framework/src/Illuminate/Log/Logger.ph

:/home/ubuntu# tail /var/www/BookStack/storage/logs/laravel.log
[stacktrace]
#0 /var/www/BookStack/vendor/symfony/console/Command/Command.php(321): Symfony\\Component\\Console\\Input\\Input->validate()
#1 /var/www/BookStack/vendor/laravel/framework/src/Illuminate/Console/Command.php(180): Symfony\\Component\\Console\\Command\\Command->run()
#2 /var/www/BookStack/vendor/symfony/console/Application.php(1096): Illuminate\\Console\\Command->run()
#3 /var/www/BookStack/vendor/symfony/console/Application.php(324): Symfony\\Component\\Console\\Application->doRunCommand()
#4 /var/www/BookStack/vendor/symfony/console/Application.php(175): Symfony\\Component\\Console\\Application->doRun()
#5 /var/www/BookStack/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(201): Symfony\\Component\\Console\\Application->run()
#6 /var/www/BookStack/artisan(35): Illuminate\\Foundation\\Console\\Kernel->handle()
#7 {main}
"}

Hosting Environment

PHP8.3, Ubuntu 24.02, nginx 1.26.1, MariaDB

@ssddanbrown
Copy link
Member

By those nginx error logs, looks like filesystem permissions are off.
See our guidance here on filesystem permissions:
https://www.bookstackapp.com/docs/admin/filesystem-permissions/

@Jeffrey-FB
Copy link
Author

Jeffrey-FB commented Jun 4, 2024

Hey @ssddanbrown

the default user is ubuntu
I've tried all those permissions a few times step by step the only change would have been.
sudo chown -R ubuntu:nginx /var/www/bookstack
I've just redone them.
And then i restarted the server

What have i missed?
drwxr-xr-x 16 ubuntu nginx 4096 Jun 4 16:34 BookStack
/var/www/BookStack/storage/logs
-rwxrwxr-x 1 ubuntu nginx 11699 Jun 4 16:12 laravel.log

@ssddanbrown
Copy link
Member

@Jeffrey-FB PHP used with nginx on Ubuntu would typically be running as the www-data user, not nginx unless this is not a standard Ubuntu environment and/or you've made changes to how PHP/nginx is running.

@Jeffrey-FB
Copy link
Author

Thanks Dan

I couldn't figure this one out as I was following multiple guides.
As i'm trying to host the DB on a remote server.

I've rebuilt it just using your install script, now I'm just trying to point it to the remote DB.
Might spin up a new ticket regarding that as i cannot seem to link it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants