I can't seem to get my datasource added using jetty-maven plugin. There are no errors thrown but when i look in the context the datasource has not been added. I have verified that the path to the file is correct and that its is parsing it(putting in incorrect class names leads to error's). I have tried using the tag and configuring as a WebAppContext configuration but this file is being completely ignored.
pom.xml
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
<version>8.1.3.v20120416</version>
<configuration>
<jettyXml>somePath/jetty.xml</jettyXml>
</configuration>
<dependencies>
<dependency>
<groupId>postgresql</groupId>
<artifactId>postgresql</artifactId>
<version>9.0-801.jdbc4</version>
</dependency>
</dependencies>
</plugin>
jetty.xml
<Configure class="org.eclipse.jetty.server.Server">
<New id="jdbc/postgres" class="org.eclipse.jetty.plus.jndi.Resource">
<Arg>jdbc/postgres</Arg>
<Arg>
<New class="org.postgresql.ds.PGSimpleDataSource">
<Set name="User">postgres</Set>
<Set name="Password">postgres</Set>
<Set name="DatabaseName">myDB</Set>
<Set name="ServerName">localhost</Set>
<Set name="PortNumber">5432</Set>
</New>
</Arg>
</New>
Java Code
Context ctx = new InitialContext();
Context context = (Context) ctx.lookup("java:comp/env");
ds = (DataSource) context.lookup("jdbc/postgres");
Any help would be appreciated.