网络别名:如何在arquillian.xml中指定它们

时间:2018-12-16 03:39:42

标签: jboss-arquillian

我在arquillian.xml中使用CUBE格式,并且有类似的内容,但是别名似乎不起作用,我丢失了什么吗?

<extension qualifier="docker">
        <property name="serverVersion">1.30</property>
        <property name="definitionFormat">CUBE</property>
         <property name="autoStartContainers">regexp:(.*)</property>

<property name="dockerContainers">
      networks:
         automationNetwork*:
            driver: bridge
      tomcat:
        image: tutum/tomcat:8.0
        exposedPorts: [8089/tcp]
        env: [JAVA_OPTS=-Dcom.sun.management.jmxremote.port=8089 -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false]
        portBindings: [8080/tcp, 8089/tcp]
        networkMode: automationNetwork*
        await:
            strategy: polling
      cart*:
        image: cicd/my-fake-service:latest
        portBindings: [8080/tcp]
        networks:
            automationNetwork*:
                  aliases: cartHost
        await:
            strategy: polling
      slotService*:
        image: cicd/my-fake-service:latest
        portBindings: [8080/tcp]
        networks:
              automationNetwork*:
                 aliases: slotHost
        await:
            strategy: polling
      shippngService*:
        image: cicd/my-fake-service:latest
        portBindings: [8080/tcp]
        await:
            strategy: polling
      paymentService*:
        image: cicd/my-fake-service:latest
        portBindings: [8080/tcp]
        await:
            strategy: polling
    </property>
    <property name="clean">true</property>
</extension>

从命令行中,我能够运行docker命令并创建别名并使用别名连接容器。

0 个答案:

没有答案