Canadian Pacific Railway says it will eliminate 130 jobs in the coming months after giving notice that it will close its locomotive repair and maintenance centre in Calgary's Alyth Yard.

The work will be transferred to other CP maintenance facilities.

The railway says the decision follows the Canadian Transportation Agency's order to cease certain overnight operations at the 60-year-old facility.

"The CTA order fails to recognize the 24-7 operational requirements and restricts the railway's ability to provide service for customers in Calgary, throughout North America, and those relying on coastal ports for off-shore shipments," said the company in a release.

The rail yard has been a sore spot with surrounding neighbours for years. Residents living in the nearby inner-city community of Inglewood have long complained about noise from the Alyth Yard.

Complaints intensified in recent years after CP consolidated train servicing work at the location, doubling the size of the operation and operating longer hours.

CTA ordered the rail company to take steps to curb the noise in early August.

Local residents also protested against CP at a recent gathering to voice concerns about dangerous goods being transported close to residential areas after a derailment at the Calgary yard last week.

Several cars carrying flammable liquids came off the tracks as a slow-moving train was heading northbound out of the Alyth Yard last Wednesday.

With files from CBC News