001 package org.kuali.common.deploy;
002
003 import java.util.ArrayList;
004 import java.util.List;
005
006 import org.kuali.common.util.DefaultProjectContext;
007 import org.kuali.common.util.MavenConstants;
008 import org.kuali.common.util.Str;
009
010 public class DeployProjectContext extends DefaultProjectContext {
011
012 private static final String ARTIFACT_ID = "kuali-deploy";
013 private static final List<String> LOCATIONS = getLocations();
014
015 public DeployProjectContext() {
016 super(ARTIFACT_ID, new ArrayList<String>(LOCATIONS));
017 }
018
019 private static final List<String> getLocations() {
020 List<String> locations = new ArrayList<String>();
021 locations.add("classpath:" + Str.getPath(MavenConstants.KUALI_COMMON_GROUP_ID) + "/deploy/deploy.properties");
022 locations.add("classpath:" + Str.getPath(MavenConstants.KUALI_COMMON_GROUP_ID) + "/deploy/driver.properties");
023 locations.add("classpath:${project.groupId.path}/deploy.properties");
024 locations.add("classpath:${project.groupId.path}/${project.artifactId}.properties");
025 locations.add("classpath:${project.groupId.path}/env${deploy.env}.properties");
026 return locations;
027 }
028
029 }