Server requirements
Ruby Systems ANPR is designed for a standard PHP/MySQL web server. The application package includes an installer and full deployment guide.
anpr.yourdomain.com.Use this section when a camera is capturing vehicles but nothing appears in Ruby ANPR, when IN/OUT looks wrong, or when a server configuration is blocking the Hikvision event.
Ruby Systems ANPR is designed for a standard PHP/MySQL web server. The application package includes an installer and full deployment guide.
anpr.yourdomain.com.After adding a camera in Ruby ANPR, use the generated API key in the camera's Alarm Server configuration.
The exact Hikvision menu varies by firmware. On supported models the setting is normally under Event / Alarm Setting / Alarm Server or the equivalent Road Traffic linkage configuration.
The Hikvision Alarm Server must be able to POST directly to /ingest.php over plain HTTP port 80. A hosting-panel or Apache Force HTTPS redirect can return HTTP 301 before PHP receives the event. Some Hikvision cameras do not follow that redirect correctly.
Keep HTTPS enabled for the normal portal, but exempt /ingest.php from HTTP-to-HTTPS redirection. The supplied Ruby ANPR .htaccess contains this exception. If your hosting panel creates a vhost-level redirect before .htaccess, disable the panel's Force HTTPS option for the ANPR hostname and let the supplied rules handle normal browser redirects.
Configure the Hikvision Alarm Server with the ANPR hostname. Posting to a shared server IP can land in the wrong Apache virtual host even when the server itself is reachable.
For the ANPR subdomain, a direct path from the camera to the web server is the simplest and most predictable configuration. If Cloudflare proxying causes camera events to disappear, set only the ANPR DNS record to DNS only while leaving the rest of the domain on Cloudflare if desired.
After changing DNS, some cameras may retain an old address briefly. Rebooting the camera forces a fresh DNS lookup.
Ruby ANPR maps Hikvision forward to IN and reverse/backward to OUT. If a camera sends only one direction, the portal will correctly show only that direction.
In the Hikvision Road Traffic / Arming Schedule and Linkage Method settings, configure the required linkage for both Forward and Reverse if you want events generated in both directions. Also confirm the detection line and lane geometry are correct.
Do not rely on the Hikvision Test button as the final proof. On some firmware versions the test can report unavailable while genuine ANPR multipart POSTs work normally. Always validate with a real vehicle detection and the Ruby ANPR dashboard or server access log.
A 401 response means Ruby ANPR was reached, but the supplied camera API key was not accepted. Confirm the whole generated URL was copied into the camera. If the key has been exposed or is uncertain, use Rotate API key in the Cameras page and update the camera.
?key=TEST request returning 401 is a useful server test because it proves PHP reached the ingest endpoint directly.Check that the site's capture storage directory is writable by the PHP user and that PHP Fileinfo is enabled. Compatible Hikvision vehicleDetection events normally provide licensePlatePicture, vehiclePicture and detectionPicture.
Do not make the storage directory publicly browsable. Ruby ANPR serves stored images through its authenticated image endpoint.
Work from the network inward. First confirm DNS, then HTTP, then Apache logs, then PHP/database behaviour. Changing multiple settings at once makes camera faults much harder to isolate.
A genuine event should appear as a POST to /ingest.php?key=..., normally with eventType=vehicleDetection, registration, direction and confidence metadata.
Send the symptoms and the stage that is failing. Avoid sending passwords or live camera API keys.