Внедрение документации

This commit is contained in:
2025-06-21 20:36:50 +08:00
parent 2f3bea76f4
commit 7e5a0bcebd
5 changed files with 47 additions and 14 deletions

View File

@@ -20,13 +20,13 @@ services:
<<: *common-attributes
container_name: iptv-keydb
image: eqalpha/keydb:latest
user: "${KEYDB_UID}:${KEYDB_GID}"
user: ${KEYDB_UID}:${KEYDB_GID}
volumes:
- ./docker/keydb/keydb.conf:/etc/keydb/keydb.conf
- ./docker/keydb/data/:/data:rw
- ./log/keydb:/var/log/keydb/:rw
ports:
- "${KEYDB_PORT:-6379}:6379"
- ${KEYDB_PORT:-6379}:6379
web:
<<: *common-attributes
@@ -39,7 +39,6 @@ services:
- ./docker/php/${IPTV_ENV}/www.conf:/usr/local/etc/php-fpm.d/www.conf:ro
- ./docker/php/${IPTV_ENV}/php.ini:/usr/local/etc/php/conf.d/php.ini:ro
- ./playlists/playlists.ini:/var/www/config/playlists.ini
# - ./playlists/channels.json:/var/www/config/channels.json
- ./log/php:/var/log/php:rw
- ./web:/var/www:rw
depends_on:
@@ -78,8 +77,9 @@ services:
- ./docker/nginx/vhost.conf:/etc/nginx/conf.d/default.conf:ro
- ./log/nginx:/var/log/nginx:rw
- ./web:/var/www:ro
- ./docs/site:/usr/share/nginx/html/doc-files:ro
ports:
- "8080:80"
- 8080:80
links:
- web
depends_on:

View File

@@ -1,8 +1,14 @@
server {
server_name iptv.local;
listen 80;
root /var/www/public;
index index.php;
index index.html index.php;
# access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log warn;
add_header Access-Control-Allow-Origin '*';
add_header Access-Control-Allow-Methods 'GET, POST, OPTIONS';
add_header Access-Control-Allow-Headers "*";
add_header Access-Control-Allow-Credentials "true";
gzip on;
gzip_vary on;
gzip_proxied any;
@@ -10,15 +16,29 @@ server {
gzip_buffers 16 8k;
gzip_http_version 1.1;
gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
location ~* \.(jpg|jpeg|gif|css|png|js|ico|html)$ {
access_log off;
expires max;
log_not_found off;
location = /docs {
return 301 /docs/;
}
location ^~ /docs/ {
alias /usr/share/nginx/html/doc-files/;
index index.html;
# access_log /var/log/nginx/docs_access.log;
error_log /var/log/nginx/docs_error.log warn;
location ~* \.(?:js|css|png|jpg|jpeg|gif|ico|svg)$ {
expires 1y;
add_header Cache-Control "public";
}
}
location / {
root /var/www/public;
try_files $uri $uri/ /index.php$is_args$args;
}
location ~ \.php$ {
root /var/www/public;
try_files $uri /index.php =404;
fastcgi_pass web:9000;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
@@ -29,5 +49,17 @@ server {
fastcgi_read_timeout 300;
proxy_read_timeout 300;
include fastcgi_params;
location ~* \.(jpg|jpeg|gif|css|png|ttf|woff|svg|js|ico)$ {
access_log off;
expires max;
log_not_found off;
}
}
location ~* \.(jpg|jpeg|gif|css|png|ttf|woff|svg|js|ico)$ {
root /var/www/public;
access_log off;
expires max;
log_not_found off;
}
}

View File

@@ -29,6 +29,6 @@ COPY --from=composer /usr/bin/composer /usr/local/bin/composer
RUN git config --global --add safe.directory /var/www
EXPOSE 9000
WORKDIR /var/www
RUN composer install
ENTRYPOINT php-fpm --nodaemonize
WORKDIR /var/www/
CMD composer install && \
php-fpm --nodaemonize

1
docs Submodule

Submodule docs added at 3a2eca9e15

2
iptv
View File

@@ -21,7 +21,7 @@ else
ROOT_PATH="$(pwd)"
fi
IPTV_PROJECTS=("iptvc" "web" "playlists")
IPTV_PROJECTS=("iptvc" "docs" "web" "playlists")
IPTV_GITEA_URL_SSH="git@git.axenov.dev:IPTV"
IPTV_GITEA_URL_HTTPS="https://git.axenov.dev/IPTV"
IPTV_DOCKER_URL_SSH="$IPTV_GITEA_URL_SSH/iptv-docker.git"