summaryrefslogtreecommitdiff
path: root/op-mode-definitions/containers.xml.in
blob: 06f98b24e7f73d069eb3b1615a4d22cab5a561a4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<?xml version="1.0"?>
<interfaceDefinition>
  <node name="add">
    <children>
      <node name="container">
        <properties>
          <help>Add container image</help>
        </properties>
        <children>
          <tagNode name="image">
            <properties>
              <help>Pull a new image for container</help>
            </properties>
            <command>sudo ${vyos_op_scripts_dir}/containers_op.sh --pull "${4}"</command>
          </tagNode>
        </children>
      </node>
    </children>
  </node>
  <node name="delete">
    <children>
      <node name="container">
        <properties>
          <help>Delete container image</help>
        </properties>
        <children>
          <tagNode name="image">
            <properties>
              <help>Delete container image</help>
            </properties>
            <command>sudo ${vyos_op_scripts_dir}/containers_op.sh --remove "${4}"</command>
          </tagNode>
        </children>
      </node>
    </children>
  </node>
  <node name="show">
    <children>
      <node name="container">
        <properties>
          <help>Show containers</help>
        </properties>
        <command>sudo ${vyos_op_scripts_dir}/containers_op.sh --show-containers</command>
        <children>
          <leafNode name="image">
            <properties>
              <help>Delete container image</help>
            </properties>
            <command>sudo ${vyos_op_scripts_dir}/containers_op.sh --show-images</command>
          </leafNode>
        </children>
      </node>
    </children>
  </node>
</interfaceDefinition>