2016-02-27 65 views
0

任何人都知道如何在自定义karaf发行版中安装opendaylight restconf。我试图添加其余的conf功能回购,并试图做功能安装。但是,这会失败,说odl-config-persister丢失。当你尝试安装odl-config-persister时会出现另一个错误。有没有其他方法可以在karaf中安装opendaylight restconf。如何安装opendaylight restconf

+0

[在自定义karaf分发中安装odl-restconf]的可能重复(http://stackoverflow.com/questions/35671915/install-odl-restconf-in-custom-karaf-distribution) –

回答

0

启动Karaf和验证,如果你有这样的功能:在你建立你的项目

feature:install odl-restconf-all 
0

feature:list | grep 'restconf' 

如果是这样,你可以安装它,“功能:安装功能名称” ,请确保karaf/pom.xml包含以下节依赖关系标记:

<dependency> 
     <groupId>org.opendaylight.l2switch</groupId> 
     <artifactId>features-l2switch</artifactId> 
     <version>0.7.0-SNAPSHOT</version> 
     <classifier>features</classifier> 
     <type>xml</type> 
     <scope>runtime</scope> 
</dependency> 

然后,生成项目:

[your_project_root]$ mvn clean install -DskipTests 

一旦构建完成,开始karaf并安装ODL-l2switch开关

[your_project_root]$ cd karaf/target/assembly/bin/ 
[bin]$ ./karaf 
[email protected]>feature:install odl-l2switch-switch 
[email protected]> 

ODL-l2switch开关包括RESTCONF作为依赖。