Eclipse - Glassfish - Struts 2.x

Found that the other problem is with the generated org.eclipse.wst.common.component file in the .settings folder. I copied the line from EclipseWtpComponent DSL for adding a wb-resource element, but it doesn’t appear in the component file. Here’s my eclipse block so far:

eclipse {
  wtp {
    facet {
      // you can add some extra wtp facets; mandatory keys: 'name', 'version':
      facet name: 'java', version: '1.7'
      facet name: 'jst.web', version: '3.0'
      facet name: 'sun.facet', version: '9'
      facet name: 'wst.jsdt.web', version: '1.0'
        file {
        //if you want to mess with the resulting XML in whatever way you fancy
        withXml {
          def node = it.asNode()
          node.appendNode('runtime', [name: 'GlassFish 3.1.2 2'])
          node.appendNode('fixed', [facet: 'wst.jsdt.web'])
          node.appendNode('fixed', [facet: 'java'])
          node.appendNode('fixed', [facet: 'jst.web'])
        }
      }
    }
      component {
      resource sourcePath: 'extra/resource', deployPath: 'deployment/resource'
    }
  }
}