Comprehensive configuration guide for Socioboard 5.0 covering environment variables, application settings, and operational best practices.
⚠️ Important: Socioboard 5.0’s last release was in November 2019. Configuration options may be outdated. For actively maintained alternatives, consider Mixpost or Postiz.
Create or edit .env in your application root:
# ============================================
# Application Settings
# ============================================
APP_ENV=production
APP_DEBUG=false
APP_URL=https://socioboard.example.com
APP_KEY=base64:your-generated-laravel-key-here
APP_TIMEZONE=UTC
# ============================================
# Database - MySQL
# ============================================
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=socioboard
DB_USERNAME=socioboard
DB_PASSWORD=your-strong-password-here
# ============================================
# Database - MongoDB
# ============================================
MONGO_HOST=127.0.0.1
MONGO_PORT=27017
MONGO_DATABASE=socioboard
MONGO_USERNAME=socioboard
MONGO_PASSWORD=your-strong-password-here
# ============================================
# Redis (Optional - for caching)
# ============================================
REDIS_HOST=127.0.0.1
REDIS_PORT=6379
REDIS_PASSWORD=null
REDIS_DATABASE=0
# ============================================
# Mail Configuration
# ============================================
MAIL_MAILER=smtp
MAIL_HOST=smtp.example.com
MAIL_PORT=587
MAIL_USERNAME=noreply@example.com
MAIL_PASSWORD=your-smtp-password
MAIL_ENCRYPTION=tls
MAIL_FROM_ADDRESS=noreply@example.com
MAIL_FROM_NAME="${APP_NAME}"
# ============================================
# Authentication
# ============================================
ADMIN_EMAIL=admin@scb.example.com
ADMIN_PASSWORD=ChangeMe123!SecurePassword
# ============================================
# API Keys (Third-party Services)
# ============================================
# Twilio (SMS verification)
TWILIO_ACCOUNT_SID=
TWILIO_AUTH_KEY=
TWILIO_SERVICE_ID=
# ============================================
# File Storage
# ============================================
FILESYSTEM_DRIVER=local
# For S3:
# FILESYSTEM_DRIVER=s3
# AWS_ACCESS_KEY_ID=
# AWS_SECRET_ACCESS_KEY=
# AWS_DEFAULT_REGION=us-east-1
# AWS_BUCKET=your-bucket-name
# ============================================
# Session & Cache
# ============================================
SESSION_DRIVER=file
SESSION_LIFETIME=120
CACHE_DRIVER=file
QUEUE_CONNECTION=sync
# ============================================
# Logging
# ============================================
LOG_CHANNEL=errorlog
LOG_LEVEL=error
# ============================================
# CORS (Cross-Origin Resource Sharing)
# ============================================
CORS_ALLOWED_ORIGINS=https://socioboard.example.com
For Docker deployments, create docker/.env:
# ============================================
# Network Configuration
# ============================================
HTTP_PORT=80
HTTPS_PORT=443
# ============================================
# Database Credentials
# ============================================
DB_PASSWORD=generate-32-char-random-password
MYSQL_ROOT_PASSWORD=generate-32-char-random-password
MONGO_ROOT_USER=mongoroot
MONGO_ROOT_PASSWORD=generate-32-char-random-password
MONGO_PASSWORD=generate-32-char-random-password
# ============================================
# Application Settings
# ============================================
NODE_ENV=production
APP_ENV=production
APP_URL=https://socioboard.example.com
APP_DEBUG=false
# ============================================
# Admin Credentials
# ============================================
ADMIN_EMAIL=admin@scb.example.com
ADMIN_PASSWORD=ChangeMe123!SecurePassword
# ============================================
# Twilio API (Required for SMS)
# ============================================
TWILIO_ACCOUNT_SID=ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
TWILIO_AUTH_KEY=your-auth-key
TWILIO_SERVICE_ID=VAxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Each microservice has its own configuration file.
socioboard-api/Common/config/development.json){
"development": {
"username": "socioboard",
"password": "your-mysql-password",
"database": "socioboard",
"host": "127.0.0.1",
"port": 3306,
"dialect": "mysql",
"pool": {
"min": 0,
"max": 5,
"idle": 10000
}
},
"production": {
"username": "socioboard",
"password": "your-mysql-password",
"database": "socioboard",
"host": "127.0.0.1",
"port": 3306,
"dialect": "mysql",
"pool": {
"min": 2,
"max": 10,
"idle": 30000
}
}
}
Update config/development.json in each service directory:
| Service | Path |
|---|---|
| User API | socioboard-api/User/config/development.json |
| Feeds API | socioboard-api/Feeds/config/development.json |
| Publish API | socioboard-api/Publish/config/development.json |
| Notification API | socioboard-api/Notification/config/development.json |
| Update API | socioboard-api/Update/config/development.json |
Example service configuration:
{
"port": 3001,
"mongoDb": {
"host": "mongodb://localhost:27017",
"database": "socioboard"
},
"mysql": {
"host": "127.0.0.1",
"port": 3306,
"database": "socioboard",
"username": "socioboard",
"password": "your-password"
},
"twilio": {
"accountSid": "ACxxxxxxxx",
"authKey": "your-key",
"serviceId": "VAxxxxxxxx"
}
}
socioboard-web-php/.env)# Application
APP_NAME=Socioboard
APP_ENV=production
APP_KEY=base64:generated-key
APP_DEBUG=false
APP_URL=https://socioboard.example.com
# Database
DB_CONNECTION=mysql
DB_HOST=mysql
DB_PORT=3306
DB_DATABASE=socioboard
DB_USERNAME=socioboard
DB_PASSWORD=your-password
# Node.js Services URLs
USER_SERVICE_URL=http://localhost:3001
FEEDS_SERVICE_URL=http://localhost:3002
PUBLISH_SERVICE_URL=http://localhost:3003
NOTIFICATION_SERVICE_URL=http://localhost:3004
UPDATE_SERVICE_URL=http://localhost:3005
# Queue
QUEUE_CONNECTION=database
# Session
SESSION_DRIVER=redis
SESSION_CONNECTION=default
SESSION_LIFETIME=120
# Cache
CACHE_DRIVER=redis
cd socioboard-web-php
php artisan key:generate
Create /etc/nginx/sites-available/socioboard:
server {
listen 80;
server_name socioboard.example.com;
# Redirect to HTTPS
return 301 https://$server_name$request_uri;
}
server {
listen 443 ssl http2;
server_name socioboard.example.com;
# SSL Configuration
ssl_certificate /etc/letsencrypt/live/socioboard.example.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/socioboard.example.com/privkey.pem;
ssl_session_timeout 1d;
ssl_session_cache shared:SSL:50m;
ssl_session_tickets off;
# Modern TLS
ssl_protocols TLSv1.2 TLSv1.3;
ssl_ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384;
ssl_prefer_server_ciphers off;
# Security Headers
add_header Strict-Transport-Security "max-age=63072000" always;
add_header X-Frame-Options "SAMEORIGIN" always;
add_header X-Content-Type-Options "nosniff" always;
add_header X-XSS-Protection "1; mode=block" always;
add_header Referrer-Policy "strict-origin-when-cross-origin" always;
# Rate Limiting
limit_req_zone $binary_remote_addr zone=general:10m rate=30r/s;
limit_req_zone $binary_remote_addr zone=api:10m rate=10r/s;
limit_req zone=general burst=20 nodelay;
# Main Application
location / {
proxy_pass http://127.0.0.1:8000;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Port $server_port;
proxy_connect_timeout 60s;
proxy_send_timeout 60s;
proxy_read_timeout 60s;
}
# API Rate Limiting
location /api/ {
limit_req zone=api burst=10 nodelay;
proxy_pass http://127.0.0.1:8000;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
# Block Sensitive Paths
location ~ /\. {
deny all;
}
location ~ /(\.git|\.env|composer\.(json|lock)) {
deny all;
return 404;
}
# Static Files
location ~* \.(jpg|jpeg|png|gif|ico|css|js|svg|woff|woff2|ttf|eot)$ {
expires 1y;
add_header Cache-Control "public, immutable";
}
}
https://socioboard.example.com/auth/facebook/callbackhttps://socioboard.example.com/auth/twitter/callback| Role | Permissions |
|---|---|
| Admin | Full access, user management, settings |
| Manager | Create/edit posts, manage accounts, view analytics |
| Author | Create posts, schedule content |
| Viewer | View-only access to analytics and posts |
For production, use database queue:
# .env
QUEUE_CONNECTION=database
Create queue table:
php artisan queue:table
php artisan migrate
Start queue worker:
# Using systemd service
sudo systemctl start socioboard-queue
# Or with supervisor
php artisan queue:work --sleep=3 --tries=3
Add to crontab:
* * * * * cd /path/to/socioboard-web-php && php artisan schedule:run >> /dev/null 2>&1
#!/bin/bash
DATE=$(date +%Y%m%d_%H%M%S)
BACKUP_DIR=/var/backups/socioboard
# MySQL backup
mysqldump -u socioboard -p socioboard > $BACKUP_DIR/mysql_$DATE.sql
# MongoDB backup
mongodump --db socioboard --out $BACKUP_DIR/mongo_$DATE
# Compress
gzip $BACKUP_DIR/mysql_$DATE.sql
tar -czf $BACKUP_DIR/mongo_$DATE.tar.gz -C $BACKUP_DIR mongo_$DATE
rm -rf $BACKUP_DIR/mongo_$DATE
# Cleanup old backups
find $BACKUP_DIR -mtime +7 -delete
MySQL Restore:
mysql -u socioboard -p socioboard < backup.sql
MongoDB Restore:
mongorestore --db socioboard backup/
Configure monitoring for /health endpoint:
curl -f https://socioboard.example.com/health || exit 1
# Application logs
tail -f /var/log/socioboard/app.log
# Nginx logs
tail -f /var/log/nginx/access.log
tail -f /var/log/nginx/error.log
# Docker logs
docker logs -f socioboard-app
| Metric | Threshold | Action |
|---|---|---|
| Response Time | > 2s | Investigate |
| Error Rate | > 1% | Alert |
| Queue Size | > 100 | Scale workers |
| Disk Usage | > 80% | Cleanup |
| Memory Usage | > 90% | Scale resources |
Environment variables not loading:
# Clear config cache
php artisan config:clear
php artisan cache:clear
Database connection errors:
# Test MySQL connection
mysql -u socioboard -p -e "SELECT 1"
# Test MongoDB connection
mongosh --username socioboard --password
Queue not processing:
# Check queue worker status
ps aux | grep queue:work
# Restart queue
php artisan queue:restart
Any questions?
Feel free to contact us. Find all contact information on our contact page.