Getting Started
Learn how to deploy Auth server application to the shared hosting provider.
- Known issues: Check the issues' section if you encounter a deployment problem. We list all the solution that fixes issues arise during deployment.
- Deployment steps: Follow along these steps to ensure a successful deployment
Setting-up
- First config the .env file to the production environment.
APP_ENV=production
APP_DEBUG=false
APP_URL=https://auth.peoplenpartners.com
# Database configuration. These config might change or differ please refer to the team for verification
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=hkoqpsophalchey_oauth
DB_USERNAME=hkoqpsophalchey_oauth
DB_PASSWORD=RB*PJ!!5f(0UY@XJ
- Clear the cache configuration
php artisan optimize:clear
- Build the client side
No SSR
npm run build
- Zip project
Zip the whole project files after a successful build of a client side.
- Upload to the server file
- Firstly, log into our shared hosting provider (e.g., 1Byte, NameKh,...).
- Locate the server folder name auth.peoplenpartners.com
- Upload the Zip file to this location.
- Once the upload completes successfully extract it, move all those files into to root folder of this location.
- Add or modify the
.htaccessto redirect all requests to the public folder, below is the.htaccessconfig
<IfModule mod_rewrite.c>
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{REQUEST_URI} !^/public/
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ /public/$1
RewriteRule ^(/)?$ public/index.php [L]
</IfModule>
- View the results
Check the site by visiting the auth.peoplenpartners.com to see if it up and running.
