feat: restructure into XFlow monorepo with Nuxt 4, Modular Onion Monolith, Android client, and Desktop CLI

This commit is contained in:
2026-09-28 10:39:19 +05:00
parent edcd30c829
commit be68f5e130
204 changed files with 24616 additions and 39 deletions
+154
View File
@@ -0,0 +1,154 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>XFlow Server</title>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
min-height: 100vh;
display: flex;
align-items: center;
justify-content: center;
color: white;
}
.container {
text-align: center;
padding: 2rem;
}
h1 {
font-size: 3rem;
margin-bottom: 1rem;
text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}
p {
font-size: 1.2rem;
margin-bottom: 2rem;
opacity: 0.9;
}
.services {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
gap: 1.5rem;
max-width: 800px;
margin: 0 auto;
}
.service-card {
background: rgba(255, 255, 255, 0.1);
backdrop-filter: blur(10px);
border-radius: 16px;
padding: 1.5rem;
border: 1px solid rgba(255, 255, 255, 0.2);
transition: transform 0.3s, box-shadow 0.3s;
}
.service-card:hover {
transform: translateY(-5px);
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}
.service-card h3 {
font-size: 1.3rem;
margin-bottom: 0.5rem;
}
.service-card p {
font-size: 0.95rem;
margin-bottom: 1rem;
}
.service-card a {
display: inline-block;
padding: 0.5rem 1.5rem;
background: white;
color: #667eea;
text-decoration: none;
border-radius: 25px;
font-weight: 600;
transition: all 0.3s;
}
.service-card a:hover {
background: #f0f0f0;
transform: scale(1.05);
}
.status {
margin-top: 2rem;
padding: 1rem;
background: rgba(255, 255, 255, 0.1);
border-radius: 8px;
display: inline-block;
}
.status-indicator {
display: inline-block;
width: 10px;
height: 10px;
background: #4ade80;
border-radius: 50%;
margin-right: 0.5rem;
animation: pulse 2s infinite;
}
@keyframes pulse {
0%,
100% {
opacity: 1;
}
50% {
opacity: 0.5;
}
}
</style>
</head>
<body>
<div class="container">
<h1>🚀 XFlow Server</h1>
<p>XFlow CRM Server</p>
<div class="services">
<div class="service-card">
<h3>📚 Git Repository</h3>
<p>Self-hosted Git server</p>
<a href="/git/" target="_blank">Open Gitea</a>
</div>
<div class="service-card">
<h3>🔌 API</h3>
<p>REST API for CRM operations</p>
<a href="/api/health" target="_blank">Check API</a>
</div>
<div class="service-card">
<h3>📱 WebDAV</h3>
<p>Direct file access</p>
<a href="http://a-crm.controlsystem.kz:8084" target="_blank">Open WebDAV</a>
</div>
</div>
<div class="status">
<span class="status-indicator"></span>
<span>Server is running</span>
</div>
</div>
</body>
</html>
+108
View File
@@ -0,0 +1,108 @@
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
# Logging
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /var/log/nginx/access.log main;
error_log /var/log/nginx/error.log;
# Gzip compression
gzip on;
gzip_vary on;
gzip_min_length 1024;
gzip_types text/plain text/css application/json application/javascript text/xml application/xml;
# Resolver for Docker DNS
resolver 127.0.0.11 valid=30s;
# Main server - serves static files and proxies to services
server {
listen 80;
server_name _;
# For Let's Encrypt challenges
location /.well-known/acme-challenge/ {
root /var/www/certbot;
}
# Health check endpoint
location /health {
access_log off;
return 200 "healthy\n";
add_header Content-Type text/plain;
}
# API proxy
location /api/ {
set $api_backend xflow-api:8080;
proxy_pass http://$api_backend;
proxy_http_version 1.1;
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_connect_timeout 60s;
proxy_send_timeout 60s;
proxy_read_timeout 60s;
}
# Gitea proxy
location /git/ {
set $gitea_backend gitea:3000;
proxy_pass http://$gitea_backend/;
proxy_http_version 1.1;
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-Prefix /git;
}
# Default - static files
location / {
root /usr/share/nginx/html;
try_files $uri $uri/ /index.html;
}
}
# HTTPS server (uncomment when SSL certificates are ready)
# server {
# listen 443 ssl http2;
# server_name your-domain.com;
#
# ssl_certificate /etc/letsencrypt/live/your-domain.com/fullchain.pem;
# ssl_certificate_key /etc/letsencrypt/live/your-domain.com/privkey.pem;
#
# location / {
# root /usr/share/nginx/html;
# try_files $uri $uri/ /index.html;
# }
#
# location /api/ {
# proxy_pass http://xflow_api/;
# proxy_http_version 1.1;
# 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;
# }
#
# location /git/ {
# proxy_pass http://gitea/;
# proxy_http_version 1.1;
# 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;
# }
# }
}