Cookie Consent
$ cd /var/www
$ sudo chown YourUbuntuUserName html'yourusername' is your username on Ubuntu desktop.
$ sudo apt install -y ffmpeg exiftran
$ sudo apt update
$ sudo apt install git
$ cd /var/www/html
$ git clone -b stable --single-branch https://github.com/nikistag/prvstorage.git prvstorage
$ mv prvstorage mystorageThen
$ sudo chown -R YourUbuntuUserName mystorage
$ cd mystorage
$ sudo chgrp -R www-data storage bootstrap/cache
$ sudo chmod -R ug+rwx storage bootstrap/cache
$ sudo usermod -a -G www-data YourUbuntuUserName
$ cd /var/www/html/mystorage
$ cp .env.example .env
$ nano .envLines marked in red are mendatory.
APP_NAME=PrvstorageFor the blue part, if you do configure mail on application, don't forget to change:
APP_ENV=local
APP_KEY=
APP_DEBUG=true
APP_URL=http://localhost
LOG_CHANNEL=stack
LOG_LEVEL=debug
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=yourMysqlDatabase
DB_USERNAME=yourMysqlUsername
DB_PASSWORD=yourMysqlUserPassword
BROADCAST_DRIVER=log
CACHE_DRIVER=file
FILESYSTEM_DRIVER=local
QUEUE_CONNECTION=sync
SESSION_DRIVER=file
SESSION_LIFETIME=120
MEMCACHED_HOST=127.0.0.1
REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379
MAIL_CONFIGURATION=null
MAIL_MAILER=smtp
MAIL_HOST=mailhog
MAIL_PORT=1025
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
MAIL_FROM_ADDRESS=null
MAIL_FROM_NAME="${APP_NAME}"
AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_DEFAULT_REGION=us-east-1
AWS_BUCKET=
AWS_USE_PATH_STYLE_ENDPOINT=false
PUSHER_APP_ID=
PUSHER_APP_KEY=
PUSHER_APP_SECRET=
PUSHER_APP_CLUSTER=mt1
MIX_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
MIX_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"
MAIL_CONFIGURATION=nullto
MAIL_CONFIGURATION=trueand modify variables acordingly.
MAIL_CONFIGURATION=trueMail is needed for passwords resets.
MAIL_MAILER=smtp
MAIL_HOST=mailhog
MAIL_PORT=1025
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
MAIL_FROM_ADDRESS=null
MAIL_FROM_NAME="${APP_NAME}"
$ php artisan key:generate
$ php artisan migrateIf you were asked a yes/no question .... just type yes and hit ENTER.
$ php artisan storage:link
$ cd /etc/apache2/sites-availableType the fallowing command and hit ENTER to identify apache configuration files.
$ ls -lThere ar two configuration files:
$ sudo cp 000-default.conf prvstorage.conf
$ sudo nano prvstorage.confChange line
DocumentRoot /var/www/htmlto
DocumentRoot /var/www/html/mystorage/publicWhere mystorage should be replaced with the name of the folder/directory of your application.
$ sudo a2dissite 000-default.conf
$ sudo a2ensite prvstorage.conf
$ sudo systemctl restart apache2