Fix: nginx duplicate MIME type, update version to 0.2.1, improve log rotation
Some checks failed
Deploy to Production / Deploy to Server (push) Failing after 22s
Some checks failed
Deploy to Production / Deploy to Server (push) Failing after 22s
- Remove duplicate text/html from nginx gzip_types (fixes nginx -t warning) - Update hardcoded API version from 0.2.0 to 0.2.1 to match package.json - Update logrotate config: daily rotation, 7 days retention, improved postrotate - Add Docker logging configuration with size/file limits
This commit is contained in:
parent
7b55a1ddc6
commit
76714d799e
4 changed files with 11 additions and 7 deletions
|
|
@ -26,6 +26,11 @@ services:
|
||||||
- PAGES_PER_BROWSER=15
|
- PAGES_PER_BROWSER=15
|
||||||
volumes:
|
volumes:
|
||||||
- docfast-data:/app/data
|
- docfast-data:/app/data
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "10m"
|
||||||
|
max-file: "3"
|
||||||
mem_limit: 2560m
|
mem_limit: 2560m
|
||||||
cpus: 1.5
|
cpus: 1.5
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,13 +1,13 @@
|
||||||
/var/log/docfast*.log {
|
/var/log/docfast/*.log {
|
||||||
weekly
|
daily
|
||||||
rotate 4
|
rotate 7
|
||||||
compress
|
compress
|
||||||
delaycompress
|
delaycompress
|
||||||
missingok
|
missingok
|
||||||
notifempty
|
notifempty
|
||||||
create 644 root root
|
create 644 root root
|
||||||
postrotate
|
postrotate
|
||||||
# Send USR1 signal to dockerized apps to reopen log files
|
# Restart docker container to reopen log files
|
||||||
/bin/kill -USR1 $(cat /var/run/docker.pid 2>/dev/null) 2>/dev/null || true
|
docker restart docfast-docfast-1 >/dev/null 2>&1 || true
|
||||||
endscript
|
endscript
|
||||||
}
|
}
|
||||||
|
|
@ -9,7 +9,6 @@ server {
|
||||||
gzip_min_length 1024;
|
gzip_min_length 1024;
|
||||||
gzip_types
|
gzip_types
|
||||||
text/plain
|
text/plain
|
||||||
text/html
|
|
||||||
text/css
|
text/css
|
||||||
application/json
|
application/json
|
||||||
application/javascript
|
application/javascript
|
||||||
|
|
|
||||||
|
|
@ -183,7 +183,7 @@ app.get("/docs", (_req, res) => {
|
||||||
app.get("/api", (_req, res) => {
|
app.get("/api", (_req, res) => {
|
||||||
res.json({
|
res.json({
|
||||||
name: "DocFast API",
|
name: "DocFast API",
|
||||||
version: "0.2.0",
|
version: "0.2.1",
|
||||||
endpoints: [
|
endpoints: [
|
||||||
"POST /v1/signup/free — Get a free API key",
|
"POST /v1/signup/free — Get a free API key",
|
||||||
"POST /v1/convert/html",
|
"POST /v1/convert/html",
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue