Israel Lopez
← Writing

When your infrastructure eats itself.

Yesterday I was working with one of my developers trying to figure out a API project with them.

In that process we needed to review the TeamCity build. We logged into TC and found that all projects were failing to access the VCS root. In our case our Version Control System is git provided by an internal gitlab instance.

Nothing was making sense. I was able to access the gitlab server just fine, and authenticate using my credentials. I was also trying the credentials the teamcity server uses, and that also happened to work locally.

What was not working at all was accessing the git repository from within TeamCity and from the Build Agent.  We have the TeamCity Server and Build Agent as the same system. 

So I logged into that system, and tried a fresh git clone, 404.  Investigating it further in the gitlab production.log I could see the “Rack_Attack” ban indicating that the IP address of the TeamCity server was blocked. But why?  It had been running fine for almost a full year like this.

But I had a naive perspective. A full year of activity lends it self to incremental usage, early on we did not use it as much as we do now. We also updated the TeamCity and gitlab versions to latest last week, so version-wise we did change a lot.

Because it has been a few years (maybe even a decade) of administering Linux systems my skills had become a bit rusty. gitlab-omnibus was a great way to package the gitlab project into a deliverable, that I was able to manage without individually compiling/packaging/installing the various discrete components of a modern web stack.

Helpfully gitlab had some documentation for this: https://docs.gitlab.com/ce/security/rack_attack.html

Search

Loading…