Uses open context manager for templated catalogs
Uses open context manager for templated catalogs

Python 3 warns that the file isn't being properly closed. This patch
stops that warning from happening by properly closing the file.

Change-Id: I7dcb08e11dfe4ba679bcde645284b24f8cb126fd
bp: python3

himanshu-setia/keystone,ilay09/keystone,mahak/keystone,ilay09/keystone,openstack/keystone,rajalokan/keystone,cernops/keystone,himanshu-setia/keystone,ilay09/keystone,mahak/keystone,mahak/keystone,openstack/keystone,dims/keystone,dims/keystone,cernops/keystone,rajalokan/keystone,openstack/keystone,klmitch/keystone,klmitch/keystone,rajalokan/keystone