private static Element containerRootElement(ApplicationPackage applicationPackage) {
        Element element = XmlHelper.getDocument(applicationPackage.getServices()).getDocumentElement();
        String nodeName = element.getNodeName();

        if (ContainerModelBuilder.configModelIds.stream().anyMatch(id -> id.getName().equals(nodeName))) {
            return element;
        } else {
            return getContainerElementInServices(element);
        }
    }
@author Tony Vaagenes
@author gjoranv
@author ollivir
standalone-container/src/main/java/com/yahoo/container/standalone/StandaloneContainerApplication.java