Service of an application brought under this article shall be made upon the person having custody of the applicant. If the applicant is being detained under the custody of the Department of Corrections, an additional copy of the application shall be served upon the Attorney General. If the applicant is being detained under the custody of some authority other than the Department of Corrections, an additional copy of the petition shall be served upon the district attorney of the county in which the application is filed.