How to configure older project in Laravel - laravel-5

I want to run my older project after installing a new OS.
I have cloned that project in htdocs, but it is showing a 404 error in the browser.
I have run these commands:
composer install
composer update --no-script
php artisan key: generate
php artisan migrate

Related

Deploy laravel from github to heroku gives error" In order to use the Auth::routes() method, please install the laravel/ui package"

I uploaded a laravel app working fine locally on github and deployed on heroku. but I kept Getting this error when deployed on heroku. view Error Image
I tried these cmds on heroku console
composer install
composer require laravel/ui
php artisan ui bootstrap --auth
but when ever I enter "php artisan ui bootstrap --auth" it says artisan not a directory or not found but its there.
I have tried "composer dump-autoload" as well, still same..
pls help
You can't install things interactively on Heroku. At best, it will appear to work temporarily but get reverted within 24 hours. All dependencies must be declared so Heroku can install them at build time.
Run composer require laravel/ui locally, then commit your updated composer.json and composer.lock files and redeploy.

Could not open input file: artisan when running php artisan serv

I'm trying to run an existing laravel project in my new windows.
when I try
php artisan serv
in my project directory, it says
Could not open input file: artisan
I even updated composer
how to configure my old project anyway?
Please run proper command on laravel project root directory:
php artisan serve

how to make php artisan command available?

I read previous posts here about same problem but they did not solve my problem. I am running wamp latest version on windows 7 and I cloned a laravel app from github then I ran composer install on the root folder of the app and all vendors installed. however I still can not execute php artisan list on the app root folder
I tried also this command
composer global require "laravel/installer=~1.1"
but same problem also there is no laravel folder installed inside vendor folder. I dont know what laravel version used with this web app
So how I can make php artisan work ?
Update:
I opened composer.json file and I found no Laravel frame work to install !! should I return to the developer who made this or I just add Laravel package to composer.json and run composer install again ? if so what I should add to the composer.json ? I dont know which version to install !!
Your project has to have an artisan file in the root directory, otherwise the php artisan command won't work.
I had a similar issue. Fixed it by using the following command, which results in a clean installation.
composer create-project --prefer-dist laravel/laravel my-project
If errors occur, your CLI will show them.
Docs

Creating a Laravel project

I have followed a tutorial on Tuts plus called "Getting started with laravel 4". My cygwin and composer works fine. When i try installing laravel using the following command:
$ composer create-project laravel/laravel laravel
i get the following message:
Installing laravel/laravel (v4.2.0)
Downloading: 100%
Created project in laravel
[InvalidArgumentException]
Composer could not find the config file: C:\ProgramData\ComposerSetup\bin
To initialize a project, please create a composer.json file as described in
the http://getcomposer.org/ "Getting Started" section
I have also tried :
composer create-project laravel/laravel project-name --prefer-dist. but same error .
I have tried looking at the Getting Started section but I am not sure what this file should contain in a laravel project?
The correct base composer. json for a laravel project can be found at https://github.com/laravel/laravel/blob/master/composer.json
Learn How To Create Basic Laravel Project | Login & Registration | Projects In Laravel | Tilak Singh
Laravel:
https://laravel.com/
Laravel is a free, open-source PHP web framework, created by Taylor Otwell and intended for the development of web applications following the model–view–controller architectural pattern and based on Symfony.
Do following steps:
install composer on your system
Download Link: https://getcomposer.org/download/
Run Command:
composer create-project --prefer-dist laravel/laravel project_name
3.after the installation go to project directory and config the .env files
Run Command:
4. composer require laravel/ui
5. php artisan ui vue --auth
6. npm install
7. npm run dev
8. php artisan migrate
9. Run project using: php artisan serve
You can watch videos with step by step:
https://www.youtube.com/watch?v=VDEZnNExDro&t=4s
You can do it by entering this composer command:
$ composer create-project laravel/laravel projectname
This will install the required files under projectname folder

Command php artisan migrate not defined - Laravel deployment

I'm trying to deploy a locally working Laravel 4 project on a Strato server.
Locally I can execute the command php artisan migrate, but when I'm trying to execute this command on the server using PuTTY command line, it throws the following exception:
[InvalidArgumentException] Command "migrate" is not defined.
These have been my deployment steps:
Install basic laravel application locally, using composer (path variable)
Upload all files to the server. Now the warning, that a database column couldn't be found is visible. So I want to migrate the database.
Run the command php artisan migrate
When I run the command php artisan list there are a few methods listed like tail and workbench, but not the commands that I need.
PHP 5.5 and MCrypt are installed on the server.
Do I have to extend the artisan installation?
Update:
The problem seems to be the following:
Warning: Composer should be invoked via the CLI version of PHP, not
the cgi-fcgi SAPI
Futhermore there is this warning:
Warning: The lock file is not up to date with the latest changes in
composer.json. You may be getting outdated dependencies. Run update to
update them.
Running update doesn't work, because it tries to run a mising artisan argument.

Resources