Updating Elastic Agents is usually straightforward – unless you’re working in a secure, air-gapped environment where machines can’t access the internet (and thus, the Elastic Artifact Repository).
And yet this was exactly the challenge we faced. We needed a way to keep the Elastic Agents across a fleet of systems up to date, without exposing any of the production servers to the outside world.
We adapted the approach from our previous blog post (Enabling Elastic Agents Upgrades in Restricted or Closed Networks | www.neteye-blog.com) by moving the architecture “down” to the NetEye Satellites instead of in the NetEye Master Nodes, removing the need for NetEye Share which greatly improves security.
Here’s how we built a reliable, automated system to handle agent updates using Python, Ansible, and NGINX, leveraging NetEye Satellites as controlled distribution points.
Elastic’s standard upgrade mechanisms assume internet connectivity – whether to pull packages, fetch signatures, or validate versions. In highly regulated or secure environments, that’s not always an option. We needed a way to:
To meet these specifications, we adopted a hybrid approach that separates responsibilities across three layers:
This script performs the following actions:
The script is fully automated, so once it’s run, you’re left with a clean and verified set of agent installers – ready to distribute.
Next, we created a simple Ansible playbook that:
location block to expose the internal repository as an HTTPS endpointEach satellite machine effectively becomes a mirror of Elastic’s public repository – but one that is 100% internal. Agents in air-gapped networks can point to this mirror to retrieve updates, install new versions, or bootstrap themselves into a Fleet setup.
https://satellite-host/elastic-artifacts-registry/beats/elastic-agent/elastic-agent-<version>-linux-x86_64.tar.gz
It’s fast, repeatable, and completely offline.
You also need to ensure you have properly configured your Fleet Settings on Elasticsearch with the new Elastic Artifacts Repository.
This solution gives us a number of important benefits:
There’s room to evolve the system further:
If you’re running Elastic in an air-gapped or tightly controlled environment, this approach can save time, reduce risk, and bring more consistency to how you manage agents. It’s lightweight, auditable, and built entirely with open source tools – no black boxes, no surprises.
Did you find this article interesting? Are you an “under the hood” kind of person? We’re really big on automation and we’re always looking for people in a similar vein to fill roles like this one as well as other roles here at Würth Phoenix.