netgescon-master/netgescon-laravel/docs/guide/install-guide.md

150 lines
2.9 KiB
Markdown

# 🚀 NetGesCon - Guida Installazione
## 📋 Requisiti Sistema
### Server Requirements
- **PHP**: 8.1 o superiore
- **Database**: MySQL 8.0+ / PostgreSQL 13+
- **Web Server**: Apache 2.4+ / Nginx 1.18+
- **Composer**: 2.0+
- **Node.js**: 18+ (per asset building)
### Estensioni PHP Richieste
```bash
php-cli php-fpm php-mysql php-pgsql php-mbstring php-xml php-curl php-zip php-intl php-gd
```
## 🔧 Installazione
### 1. Clone Repository
```bash
git clone [repository-url] netgescon
cd netgescon
```
### 2. Dipendenze
```bash
# Composer dependencies
composer install --optimize-autoloader --no-dev
# NPM dependencies
npm ci --only=production
npm run build
```
### 3. Configurazione
```bash
# Copia file ambiente
cp .env.example .env
# Genera chiave applicazione
php artisan key:generate
# Configura database in .env
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=netgescon
DB_USERNAME=your_username
DB_PASSWORD=your_password
```
### 4. Database Setup
```bash
# Migrazione database
php artisan migrate
# Seed dati iniziali (opzionale)
php artisan db:seed --class=InitialDataSeeder
```
### 5. Permessi
```bash
# Storage e cache
sudo chown -R www-data:www-data storage bootstrap/cache
sudo chmod -R 775 storage bootstrap/cache
```
### 6. Web Server
#### Apache
```apache
<VirtualHost *:80>
ServerName netgescon.local
DocumentRoot /path/to/netgescon/public
<Directory /path/to/netgescon/public>
AllowOverride All
Require all granted
</Directory>
</VirtualHost>
```
#### Nginx
```nginx
server {
listen 80;
server_name netgescon.local;
root /path/to/netgescon/public;
index index.php;
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location ~ \.php$ {
fastcgi_pass unix:/var/run/php/php8.1-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
}
```
## 🔐 Configurazione Iniziale
### 1. Primo Accesso
- URL: `http://your-domain.com`
- L'applicazione richiederà la configurazione iniziale
### 2. Configurazione Amministratore
- Crea il primo utente amministratore
- Configura i permessi base
- Importa dati esistenti se necessario
### 3. Test Funzionalità
- Verifica login/logout
- Test creazione utenti
- Test funzionalità principali
## 🐛 Risoluzione Problemi
### Cache Issues
```bash
php artisan cache:clear
php artisan config:clear
php artisan route:clear
php artisan view:clear
```
### Permission Issues
```bash
sudo chown -R www-data:www-data storage
sudo chmod -R 775 storage
```
### Database Connection
- Verifica credenziali in `.env`
- Controlla che il database esista
- Verifica che l'utente abbia i permessi necessari
## 📞 Supporto
Per supporto tecnico o problemi di installazione:
- Documentazione: `/docs/README.md`
- Issues: GitHub Issues
- Email: [contact-email]
---
*Ultimo aggiornamento: ${new Date().toLocaleDateString('it-IT')}*