Trainline creates open source platform to help developers deploy apps and environments in AWS

Mark Holt said that previous tools were heavily 'opinionated' - driving the firm to particular solutions

The Trainline, the independent rail ticket retailer, has created an open sourced standardised way for its developers to deploy and manage individual applications and environments in Amazon Web Services' public cloud.

The company has 150 staff in its development area, who focus on improving user experience, and in order to ensure that its underlying infrastructure wasn't a constraint on time to market, the firm recently migrated all of its development, staging, UAT and production environments from a legacy private data centre to Amazon's public cloud.

Chris Turvil, head of cloud and platform agility at the Trainline, explained that in the company's legacy environment, its developers spent up to 30 per cent of their time troubleshooting technical issues such as missing versions, differences to other environments and problems with deployments.

"Consequently, we recognised that we also needed a standard way for our developers to quickly and safely deploy and manage individual applications and entire environments," he said.

Mark Holt, CTO at the Trainline, told Computing that the company spent a lot of time looking for an existing product, commercial or open source, that would meet its requirements.

"We found that most of the existing packages were heavily "opinionated" - they tried to drive us towards particular technology solutions that weren't appropriate in our multi-language, mixed Windows/Linux environment," he said.

Turvil said that tools such as Spinnaker were "opinionated" about the approach, while Kubernetes assumed everything was a container, and AWS Code Deploy led to single-tenancy. He said that nearly all tools lacked "first-class Windows support".

So after trying out several tools, the company ended up developing its own platform dubbed Environment Manager.

Turvil said that the platform was "minimally opinionated", and enabled continuous delivery of software components into Windows and Linux AWS environments. He added that it was best suited to companies with between 100 and 5,000 servers running a mixture of legacy and modern applications. It currently supports a range of deployment methods including basic overwrite, blue/green, canaries, and immutable servers. Support for containers and Lambda functions are also on the roadmap.

"Environment Manager has now become our single source of truth and approach for deploying everything into AWS," said Holt.

Holt explained that the firm felt strongly that open sourcing Environment Manager was "an opportunity for us to give back to the community".

"If we couldn't find something that worked for our deployment needs then we felt that other people ought to benefit from our experiences, just as we benefit from theirs," he stated.

The Environment Manager source code is available here, and is the same as the code used internally, and will continue to be so, according to Holt. It is licensed under the Apache 2 licence.

Holt admitted the tool is currently slightly hard to install but it is something the team is working on improving over the next few weeks.

"We use a lot of AWS Lambda and support for deploying functions should be coming soon. In time, we'd love more companies to take on the tooling and contribute their changes back," he said.