mirror of
https://github.com/thecyberlearn/quantum-website-2026.git
synced 2026-08-18 10:03:21 +00:00
remove docker config
This commit is contained in:
parent
56a3fa2cf6
commit
6a4f826b79
50
Dockerfile
50
Dockerfile
@ -1,50 +0,0 @@
|
|||||||
# Use the official nginx image based on Alpine Linux
|
|
||||||
FROM nginx:alpine
|
|
||||||
|
|
||||||
# Remove the default nginx website
|
|
||||||
RUN rm -rf /usr/share/nginx/html/*
|
|
||||||
|
|
||||||
# Copy the static website files to nginx html directory
|
|
||||||
COPY . /usr/share/nginx/html/
|
|
||||||
|
|
||||||
# Create a custom nginx configuration
|
|
||||||
RUN echo 'server {' > /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' listen 80;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' server_name _;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' root /usr/share/nginx/html;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' index index.html index.htm;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' ' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' # Handle URLs without extensions' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' location / {' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' try_files $uri $uri.html $uri/ /index.html;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' }' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' ' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' # Security headers' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' add_header X-Frame-Options "SAMEORIGIN" always;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' add_header X-Content-Type-Options "nosniff" always;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' add_header X-XSS-Protection "1; mode=block" always;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' ' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' # Static assets caching' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' location ~* \.(css|js|png|jpg|jpeg|gif|ico|svg|woff|woff2|ttf|eot)$ {' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' expires 1y;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' add_header Cache-Control "public, immutable";' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' }' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' ' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' # JSON files - shorter cache for blog data' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' location ~* \.(json)$ {' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' expires 10m;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' add_header Cache-Control "public";' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' }' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' ' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' # HTML files - shorter cache' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' location ~* \.(html|htm)$ {' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' expires 1h;' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' add_header Cache-Control "public";' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo ' }' >> /etc/nginx/conf.d/default.conf && \
|
|
||||||
echo '}' >> /etc/nginx/conf.d/default.conf
|
|
||||||
|
|
||||||
# Expose port 80
|
|
||||||
EXPOSE 80
|
|
||||||
|
|
||||||
# Start nginx in the foreground
|
|
||||||
CMD ["nginx", "-g", "daemon off;"]
|
|
||||||
@ -1,17 +0,0 @@
|
|||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
quantumtaskai-website:
|
|
||||||
build: .
|
|
||||||
container_name: quantumtaskai-website-test
|
|
||||||
restart: unless-stopped
|
|
||||||
ports:
|
|
||||||
- "8081:80" # Use port 8081 to avoid conflicts
|
|
||||||
environment:
|
|
||||||
- NODE_ENV=production
|
|
||||||
healthcheck:
|
|
||||||
test: ["CMD", "wget", "--quiet", "--tries=1", "--spider", "http://localhost:80"]
|
|
||||||
interval: 30s
|
|
||||||
timeout: 10s
|
|
||||||
retries: 3
|
|
||||||
start_period: 30s
|
|
||||||
@ -1,34 +0,0 @@
|
|||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
quantumtaskai-website:
|
|
||||||
build: .
|
|
||||||
container_name: quantumtaskai-website
|
|
||||||
restart: unless-stopped
|
|
||||||
# ports:
|
|
||||||
# - "80:80" # Removed: Traefik handles routing
|
|
||||||
environment:
|
|
||||||
- NODE_ENV=production
|
|
||||||
# networks:
|
|
||||||
# - web # Removed: using default network
|
|
||||||
labels:
|
|
||||||
# Dokploy labels for automatic configuration
|
|
||||||
- "traefik.enable=true"
|
|
||||||
- "traefik.http.routers.quantumtaskai-website.rule=Host(`quantumtaskai.com`) || Host(`www.quantumtaskai.com`)"
|
|
||||||
- "traefik.http.routers.quantumtaskai-website.tls=true"
|
|
||||||
- "traefik.http.routers.quantumtaskai-website.tls.certresolver=letsencrypt"
|
|
||||||
- "traefik.http.services.quantumtaskai-website.loadbalancer.server.port=80"
|
|
||||||
# Optional: redirect www to non-www
|
|
||||||
- "traefik.http.middlewares.www-redirect.redirectregex.regex=^https://www\\.quantumtaskai\\.com/(.*)"
|
|
||||||
- "traefik.http.middlewares.www-redirect.redirectregex.replacement=https://quantumtaskai.com/$${1}"
|
|
||||||
- "traefik.http.routers.quantumtaskai-website.middlewares=www-redirect"
|
|
||||||
healthcheck:
|
|
||||||
test: ["CMD", "curl", "-f", "http://localhost:80"]
|
|
||||||
interval: 30s
|
|
||||||
timeout: 10s
|
|
||||||
retries: 3
|
|
||||||
start_period: 30s
|
|
||||||
|
|
||||||
# networks:
|
|
||||||
# web:
|
|
||||||
# external: true
|
|
||||||
66
dokploy.json
66
dokploy.json
@ -1,66 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "quantumtaskai-website",
|
|
||||||
"type": "compose",
|
|
||||||
"description": "Quantum Tasks AI static website - AI & Cybersecurity Solutions",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"compose": {
|
|
||||||
"file": "docker-compose.yml",
|
|
||||||
"context": "."
|
|
||||||
},
|
|
||||||
"domains": [
|
|
||||||
{
|
|
||||||
"host": "quantumtaskai.com",
|
|
||||||
"https": true,
|
|
||||||
"certificateType": "letsencrypt"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"host": "www.quantumtaskai.com",
|
|
||||||
"https": true,
|
|
||||||
"certificateType": "letsencrypt",
|
|
||||||
"redirect": "https://quantumtaskai.com"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"environment": {
|
|
||||||
"NODE_ENV": "production"
|
|
||||||
},
|
|
||||||
"resources": {
|
|
||||||
"memory": "256M",
|
|
||||||
"cpu": "0.5"
|
|
||||||
},
|
|
||||||
"healthcheck": {
|
|
||||||
"enabled": true,
|
|
||||||
"path": "/",
|
|
||||||
"interval": 30,
|
|
||||||
"timeout": 10,
|
|
||||||
"retries": 3
|
|
||||||
},
|
|
||||||
"backup": {
|
|
||||||
"enabled": false
|
|
||||||
},
|
|
||||||
"monitoring": {
|
|
||||||
"enabled": true,
|
|
||||||
"metrics": ["cpu", "memory", "network"]
|
|
||||||
},
|
|
||||||
"security": {
|
|
||||||
"firewall": {
|
|
||||||
"enabled": true,
|
|
||||||
"rules": [
|
|
||||||
{
|
|
||||||
"port": 80,
|
|
||||||
"protocol": "tcp",
|
|
||||||
"source": "0.0.0.0/0"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"port": 443,
|
|
||||||
"protocol": "tcp",
|
|
||||||
"source": "0.0.0.0/0"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"deployment": {
|
|
||||||
"strategy": "rolling",
|
|
||||||
"maxUnavailable": 0,
|
|
||||||
"maxSurge": 1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,31 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "quantumtaskai-website-test",
|
|
||||||
"type": "compose",
|
|
||||||
"description": "Quantum Tasks AI website - Testing without domain",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"compose": {
|
|
||||||
"file": "docker-compose.test.yml",
|
|
||||||
"context": "."
|
|
||||||
},
|
|
||||||
"environment": {
|
|
||||||
"NODE_ENV": "production"
|
|
||||||
},
|
|
||||||
"resources": {
|
|
||||||
"memory": "256M",
|
|
||||||
"cpu": "0.5"
|
|
||||||
},
|
|
||||||
"healthcheck": {
|
|
||||||
"enabled": true,
|
|
||||||
"path": "/",
|
|
||||||
"interval": 30,
|
|
||||||
"timeout": 10,
|
|
||||||
"retries": 3
|
|
||||||
},
|
|
||||||
"ports": [
|
|
||||||
{
|
|
||||||
"containerPort": 80,
|
|
||||||
"hostPort": 8080,
|
|
||||||
"protocol": "tcp"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
Loading…
Reference in New Issue
Block a user