SShortSingh.
Back to feed

nginx -t can pass while nginx keeps serving the old config; how to deploy safely

0
·8 views

A common deploy pattern runs nginx -t and then nginx -s reload, assuming a zero exit status means the new config is live. That assumption can be wrong. The -t check parses configuration without binding listening ports, so port conflicts only surface when the master process starts listening. The reload command is also asynchronous: it only signals the master and exits, and if the master fails to apply the new config, it silently keeps the old one. The article proposes versioned config directories, an atomic symlink swap, a confirmed reload, and a fallback for when nginx fails to start.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

MAPE ranks two forecasts opposite to RMSE and breaks on zero demand

Mean absolute percentage error expresses forecast misses as percentages, which makes it easy for non-technical managers to read. On a five-day demand example, MAPE favors a forecast that RMSE judges to be more than twice as poor, because percentage errors weigh each miss against that day's actual demand. The metric is undefined when demand is zero and explodes when demand is near zero, and it penalizes over- and under-forecasts asymmetrically. The article suggests alternatives such as weighted MAPE, sMAPE, and MASE, and recommends reporting several metrics side by side on your own data.

0
ProgrammingDEV Community ·

Обзор AI-переводчиков манги и манхвы на русский в 2026: OCR, инпейнтинг и расширения

Стандартные OCR-решения хуже справляются с переводом японской манги и корейской манхвы на русский, чем с англоязычным материалом. Проблемы связаны с вертикальным письмом, фуриганой, длинными полосами вебтунов и тем, что русские реплики заметно длиннее оригинала. Выбор инструмента сводится к трём слоям: захват страниц из DOM или canvas, алгоритм удаления исходного текста и контроль кириллической верстки. Статья разбирает особенности расширений для Chromium MV3 и Firefox WebExtensions, а также сравнивает маскирование глифов с закраской белыми плашками. Приведён пример алгоритма подбора кегля для кириллического текста внутри узкого овального бабла.

0
ProgrammingDEV Community ·

AEGIS-MCP: A Zero-Trust Local Proxy Aimed at Blocking MCP Lethal Trifecta Attacks

AI coding agents using the Model Context Protocol can now read local files, ingest untrusted external content, and call outbound network tools, creating supply-chain risks. The article cites over 1,000 MCP-specific vulnerabilities and a large share of audited agent skills containing security flaws, including packages built to steal credentials. The MCP maintainers recently named the resulting risk pattern the Lethal Trifecta, noting that tool annotations alone cannot be trusted. The author presents AEGIS-MCP, an open-source (MIT) governance proxy that enforces security at the local host runtime, using taint tracking that blocks outbound actions until a human approves them. The project also includes cryptographically signed audit records and a browser-based verifier that runs without network access.

0
ProgrammingDEV Community ·

Joint Tech Warning and NSA Advisory Urge Urgent Shift to Post-Quantum Cryptography

On December 2, 2026, eight major technology companies, including Amazon, Google, Microsoft, and OpenAI, jointly called for migrating to post-quantum cryptography as soon as possible. The same day, the NSA, CISA, and the Office of the National Cyber Director issued an urgent advisory, citing private disclosures from frontier AI labs about new mathematical findings that could affect cryptographic systems in use today. Cloudflare's CEO advised assuming that anything relying on RSA or Elliptic Curve cryptography could be affected. Officials stated that there is no immediate, widespread break of live encryption, and that HTTPS and online banking remain secure for now. The article frames the development as a shift from a hardware-based timeline for quantum threats to a mathematics-driven one, with public-key systems that secure much of the internet now at the center of concern.