Here is the quick documentation to setup the web part of the Shortzz application created in PHP Laravel. Please follow all the steps correctly and carefully setup the project.
PHP 8.0 and above and it will work on any kind of hosting
Linux based hosting
memory_limit should be 120M
AWS S3 bucket and it’s credentials to store files: Please Click Here to know the steps to create S3 bucket on AWS and get the credentials.
If you face any issue in video upload or it takes time in uploading video to the server that might be because of your server. Sometimes server gives this error if you check your error log file
The Allowed memory size of 33554432 bytes exhausted (tried to allocate 15756752 bytes)
If you see this error then you would need to upgrade your server or increase PHP memory limit by going into php.ini file. you need to google about where this file is. This file resides in different locations in different servers
Extract the folder you downloaded and open the folder
Open it and find the database.sql file
Then open your cPanel provided by your web hosting provider
Click the MySQLDatabase option under DATABASES section and create database for your app
Create a Database User
Assign users to the database
After that search for phpMyadmin option under the database
Then system will redirect you to the phpMyAdmin where you will be able to find the database we just created
Click on that database
Then find the import button on the Top bar and click on it
Then click Choose File button and load the database.sql file there you got from the Extraction of folder
And click the Go button at bottom of the page
Now Database is ready to use
Now come back to the project folder and then extract shortzz_backend.zip file
Make sure you have created S3 bucket on AWS and have your credentials
In that folder, find the .env file, open it with any text editor and make the changes as asked below
There in the APP_URL (Line: 5) : Replace the https://yourdomain.com/ to Your Domain
Change Database Configuration (Line: 12 to 14), as shown in the example below
DB_DATABASE=database_name
DB_USERNAME=database_username
DB_PASSWORD=”database_password”
Change AWS S3 configuration: (Line: 44 to 48
AWS_ACCESS_KEY_ID=AWS_ACCESS_KEY
AWS_SECRET_ACCESS_KEY=”AWS_SECRET_ACCESS_KEY”
AWS_BUCKET=BUCKET_NAME
AWS_DEFAULT_REGION=AWS_REGION
DEFAULT_IMAGE_URL=URL_TO_YOUR_BUCKET
Go to your firebase project and follow the steps given below in the image
Change FCM_TOKEN for notification (Line: 50)
FCM_TOKEN=”FCM_TOKEN”
If you don’t find the fields on the line numbers we have stated, press Ctl+f and try to find that field and then change the values.
Sign up at Agora Console
Create new project, (Fill all required information and click on submit)
Click next and close the popup show like below
Tap on Project Management tab and Create Project
Create Project
Enter Your Project Name
Select Use Case And then submit
Copy App ID
Then click on config action to Get App Certificate
Now come back to the .env file again and replace those values like below.
AGORA_APP_ID=Your_agora_app_id_here
AGORA_APP_CERT=Your_agora_app_certificate_here
chmod 777 storage/logs/laravel.log
chmod 777 storage/framework/sessions/
chmod 777 storage/framework/views/
chmod 777 storage/framework/cache/data/
chmod 777 public/uploads/
Admin Panel URL: http://yourdomain.com/
Admin Panel User Name: admin
Admin Panel Password: admin123
Baseurl: http://yourdomain.com/api/
apiKey: dev123
itemBaseURL: The item base URL will be the one you have got while setting up the AWS bucket. Click here to check again
Email : help.retrytech@gmail.com