I have successfully configured and make everything work perfectly. But i have an issue, i want to change the time to live but in my project "jwt.php" does not appear in the config folder.
If anyone knows the solution kindly guide me; help will be appreciated.
Many Thanks!
This is probably because you haven't published vendor files.
You should run:
php artisan config:publish tymon/jwt-auth
assuming you use https://github.com/tymondesigns/jwt-auth package to publish configuration file so you will have jwt.php created and then you can update config according to your needs
To publish vendor files, for Laravel 5.5, run
php artisan vendor:publish --tag=config
Related
I deployed the laravel app to digitalocean:
but I don't understand why is it showing error 500??
I connected a github repo to deploy it to digitalocean.
1- I set the build commands to: composer install
2- environment variables are set: APP_NAME, APP_URL, APP_KEY, DATABASE_URL, APP_DEBUG
This is how the repo looks (private)
What seems to be the issue??
I just did check the repo and it seems the vendors folder not there and your build steps look like a typo issue so please run below command
composer install
Still you face the issue then refer the laravel logs for that what went wrong
you also dont have a .env file
maybe copy the .env.example to .env
perhaps follow the instructions on the laravel site for the version you are using.
in your question, you have spelt 'install' incorrectly
turns out there were typos of lower and upper cases in controllers according to the laravel log.
I fixed them and now the site is running. It's weird that these typos didn't trigger erorrs locally..
All You have to do is configure the .env file if u have a .example.env edit the file to .env if u dont have it just try to create one or clone one from another project and do composer install but don't forget to generate a key with php artisan key:generate in the end
According to Frontend Quickstart official documentation of laravel-5.7. I run the command:
php artisan vendor:publish --tag=passport-components
I have no any error messages, it returns:
Copied Directory
[/vendor/laravel/passport/resources/assets/js/components] To
[/resources/assets/js/components/passport]
Publishing complete.
So, it does not copied to resources/js/components like the documentation stated:
The published components will be placed in your
resources/js/components directory.
I don't know why does it published in different path other than specified in the documentation? and how could I solve this issue?
In 5.7 the resources/assets/js directory became resources/js which has been causing issues.
There is an open issue about this on the passport github page: https://github.com/laravel/passport/issues/829
When I ran php artisan serve then copy this URL http://127.0.0.1:8000/. Its works. I want to access my project via url http://localhost/myproject/public/.
It returns blank page. And when I inspect the element it returns 500. Internal server error. Appreciate your help regarding this. Thank you.
Laravel version: 5.4
Php Version: 7.1.12
I can access the folders but when accessing the public folder itself. Returns blank page.
When run the php artisan serve. Its working
I found the answer to my question. It's the PHP version. Php7.0 does not support it
You can try doing:
composer install
Or In the root of your project try to run
php -S localhost:8000 -t public/
Check this answer of my prev. question. You should set symbolic link as the docs said.
This is what I get after copying all my laravel backup files from an older version:
Someone has any idea why it happens and how to make it work?
You need to specify API_PREFIX and API_DOMAIN in the Laravel .env File and for the second screen you need to enter the project and generate a key with artisan : php artisan key:generate
I have been working on a laravel5 project on a computer , but now I want to continue on an other, but don't know how :(
I'm using wampserver and the project is in the "www" folder, this is the error I'm getting when trying to open the project: " Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request"
Your error message is very vague, so it is hard to pinpoint the cause. I assume you just copy pasted all of the project files
Try these steps:
Make sure you copy all of the project files including the hidden ones(.env).
Prepare your destination computer as in http://laravel.com/docs/
Check you have all the necessary PHP extensions available in php.ini as in above link requirements. Also, watch your PHP version!
Install composer https://getcomposer.org/doc/00-intro.md
When copied, go to your destination folder and run composer install.
Run php artisan key:generate from the command line.
Run php artisan cache:clear from command line
http://php.net/manual/en/install.windows.commandline.php
Make sure your webserver is serving pages from project/public folder.
If laravel is failing, check the log file to see the cause
your_project/storage/logs/laravel.log
Copy the project folder and navigate terminal/cmd
just run following commands.
Create database and place the same name at .env file in laravel project folder
1. composer install
2. php artisan key:generate
3. php artisan cache:clear
4. php artisan migrate
UPDATE: If you're getting
Whoops, looks like something went wrong
in app/config/app.php, set debugging as true with:
'debug' => env('APP_DEBUG', true)'
If you're getting the error
No supported encrypter found. The cipher and/or key length are invalid
for some people it worked to do cp .env.example .env before (2).
You would also have to create new storage link, because Laravel uses absolute path inside it.
php artisan storage:link
https://stackoverflow.com/a/32722141/3982831 Please follow this to resolve your problems. All people forget about permissions on folders.
After you have done as Ademord answer, you might need to use refresh to your WAMP, XAMP or any other development stack you are using. I had the same issue plus changes were not reflecting in the front end. For example new routes in the web.php were not updating.