Skip to content

Commit

Permalink
Improve Kubernetes plugin.
Browse files Browse the repository at this point in the history
Signed-off-by: Volker Theile <votdev@gmx.de>
  • Loading branch information
votdev committed Mar 26, 2024
1 parent 42bee79 commit 46a52f5
Show file tree
Hide file tree
Showing 30 changed files with 620 additions and 112 deletions.
5 changes: 2 additions & 3 deletions deb/openmediavault-k8s/debian/changelog
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
openmediavault-k8s (7.0.1-1) unstable; urgency=low

* Use Twig template engine to implement a DSL that allows users
* Use a PHP template engine to implement a DSL that allows users
to access data from the configuration database and other system
information inside their recipes.
Right at the moment the following functions are supported:
`hostname`, `domain`, `fqdn`, `uid`, `gid`, `sharedfolder_path`,
`config`. The following filters are added to those shipped with
Twig: `get`.
`conf_get`.

-- Volker Theile <volker.theile@openmediavault.org> Mon, 25 Mar 2024 19:44:24 +0100

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ class OMVRpcServiceK8s extends \OMV\Rpc\ServiceAbstract {
return build_path(DIRECTORY_SEPARATOR, $meObject->get("dir"),
$sfObject->get("reldirpath"));
},
"config" => function($id, $uuid = NULL) use($db) {
"conf_get" => function($id, $uuid = NULL) use($db) {
return $db->getAssoc($id, $uuid);
}
];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: openmediavault-k8s\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-03-16 11:53+0100\n"
"POT-Creation-Date: 2024-03-26 18:29+0100\n"
"PO-Revision-Date: 2024-03-09 09:44+0000\n"
"Last-Translator: omv nas <myomv100@gmail.com>, 2024\n"
"Language-Team: Arabic (Saudi Arabia) (https://app.transifex.com/openmediavault/teams/14254/ar_SA/)\n"
Expand All @@ -21,6 +21,9 @@ msgstr ""
"Language: ar_SA\n"
"Plural-Forms: nplurals=6; plural=(n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 && n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5);\n"

msgid "Absolute Path"
msgstr ""

msgid "Access Modes"
msgstr ""

Expand All @@ -30,6 +33,9 @@ msgstr ""
msgid "Apply"
msgstr ""

msgid "Architecture"
msgstr ""

msgid "Available"
msgstr ""

Expand Down Expand Up @@ -203,9 +209,6 @@ msgstr ""
msgid "Persistent Volumes"
msgstr ""

msgid "Persistent Volumes of Shared Folders"
msgstr ""

msgid "Pods"
msgstr ""

Expand Down Expand Up @@ -245,12 +248,18 @@ msgstr ""
msgid "Secrets"
msgstr ""

msgid "Section"
msgstr ""

msgid "Services"
msgstr ""

msgid "Settings"
msgstr ""

msgid "Shared Folders"
msgstr ""

msgid "Size"
msgstr ""

Expand All @@ -277,6 +286,16 @@ msgid ""
"not set, a self-signed certificate from cert-manager is used."
msgstr ""

msgid ""
"The following placeholders can be used in recipes to get access to global "
"system information and the configuration "
"database:<br><ul><li>hostname()</li><li>domain()</li><li>fqdn()</li><li>uid(name)</li><li>gid(name)</li><li>sharedfolder_path(name)</li><li>conf_get(id,"
" uuid=NULL)</li></ul>You have to denote placeholders with double-curly "
"braces. An overview of additional available filters can be found <a "
"href='https://twig.symfony.com/doc/filters/index.html' "
"target='_blank'>here</a>."
msgstr ""

msgid "The location where to store etcd on-demand snapshots."
msgstr ""

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: openmediavault-k8s\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-03-16 11:53+0100\n"
"POT-Creation-Date: 2024-03-26 18:29+0100\n"
"PO-Revision-Date: 2024-03-09 09:44+0000\n"
"Language-Team: Bulgarian (Bulgaria) (https://app.transifex.com/openmediavault/teams/14254/bg_BG/)\n"
"MIME-Version: 1.0\n"
Expand All @@ -17,6 +17,9 @@ msgstr ""
"Language: bg_BG\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

msgid "Absolute Path"
msgstr ""

msgid "Access Modes"
msgstr ""

Expand All @@ -26,6 +29,9 @@ msgstr ""
msgid "Apply"
msgstr ""

msgid "Architecture"
msgstr ""

msgid "Available"
msgstr ""

Expand Down Expand Up @@ -199,9 +205,6 @@ msgstr ""
msgid "Persistent Volumes"
msgstr ""

msgid "Persistent Volumes of Shared Folders"
msgstr ""

msgid "Pods"
msgstr ""

Expand Down Expand Up @@ -241,12 +244,18 @@ msgstr ""
msgid "Secrets"
msgstr ""

msgid "Section"
msgstr ""

msgid "Services"
msgstr ""

msgid "Settings"
msgstr ""

msgid "Shared Folders"
msgstr ""

msgid "Size"
msgstr ""

Expand All @@ -273,6 +282,16 @@ msgid ""
"not set, a self-signed certificate from cert-manager is used."
msgstr ""

msgid ""
"The following placeholders can be used in recipes to get access to global "
"system information and the configuration "
"database:<br><ul><li>hostname()</li><li>domain()</li><li>fqdn()</li><li>uid(name)</li><li>gid(name)</li><li>sharedfolder_path(name)</li><li>conf_get(id,"
" uuid=NULL)</li></ul>You have to denote placeholders with double-curly "
"braces. An overview of additional available filters can be found <a "
"href='https://twig.symfony.com/doc/filters/index.html' "
"target='_blank'>here</a>."
msgstr ""

msgid "The location where to store etcd on-demand snapshots."
msgstr ""

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: openmediavault-k8s\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-03-16 11:53+0100\n"
"POT-Creation-Date: 2024-03-26 18:29+0100\n"
"PO-Revision-Date: 2024-03-09 09:44+0000\n"
"Last-Translator: Quim Farriol <qfarriol@valette.cat>, 2024\n"
"Language-Team: Catalan (Spain) (https://app.transifex.com/openmediavault/teams/14254/ca_ES/)\n"
Expand All @@ -21,6 +21,9 @@ msgstr ""
"Language: ca_ES\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

msgid "Absolute Path"
msgstr ""

msgid "Access Modes"
msgstr ""

Expand All @@ -30,6 +33,9 @@ msgstr ""
msgid "Apply"
msgstr ""

msgid "Architecture"
msgstr ""

msgid "Available"
msgstr ""

Expand Down Expand Up @@ -203,9 +209,6 @@ msgstr ""
msgid "Persistent Volumes"
msgstr ""

msgid "Persistent Volumes of Shared Folders"
msgstr ""

msgid "Pods"
msgstr "Pods"

Expand Down Expand Up @@ -245,12 +248,18 @@ msgstr ""
msgid "Secrets"
msgstr ""

msgid "Section"
msgstr ""

msgid "Services"
msgstr ""

msgid "Settings"
msgstr ""

msgid "Shared Folders"
msgstr ""

msgid "Size"
msgstr "Talla"

Expand All @@ -277,6 +286,16 @@ msgid ""
"not set, a self-signed certificate from cert-manager is used."
msgstr ""

msgid ""
"The following placeholders can be used in recipes to get access to global "
"system information and the configuration "
"database:<br><ul><li>hostname()</li><li>domain()</li><li>fqdn()</li><li>uid(name)</li><li>gid(name)</li><li>sharedfolder_path(name)</li><li>conf_get(id,"
" uuid=NULL)</li></ul>You have to denote placeholders with double-curly "
"braces. An overview of additional available filters can be found <a "
"href='https://twig.symfony.com/doc/filters/index.html' "
"target='_blank'>here</a>."
msgstr ""

msgid "The location where to store etcd on-demand snapshots."
msgstr ""

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: openmediavault-k8s\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-03-16 11:53+0100\n"
"POT-Creation-Date: 2024-03-26 18:29+0100\n"
"PO-Revision-Date: 2024-03-09 09:44+0000\n"
"Last-Translator: Pavel Borecki <pavel.borecki@gmail.com>, 2024\n"
"Language-Team: Czech (Czech Republic) (https://app.transifex.com/openmediavault/teams/14254/cs_CZ/)\n"
Expand All @@ -21,6 +21,9 @@ msgstr ""
"Language: cs_CZ\n"
"Plural-Forms: nplurals=4; plural=(n == 1 && n % 1 == 0) ? 0 : (n >= 2 && n <= 4 && n % 1 == 0) ? 1: (n % 1 != 0 ) ? 2 : 3;\n"

msgid "Absolute Path"
msgstr ""

msgid "Access Modes"
msgstr ""

Expand All @@ -30,6 +33,9 @@ msgstr ""
msgid "Apply"
msgstr ""

msgid "Architecture"
msgstr ""

msgid "Available"
msgstr ""

Expand Down Expand Up @@ -203,9 +209,6 @@ msgstr ""
msgid "Persistent Volumes"
msgstr ""

msgid "Persistent Volumes of Shared Folders"
msgstr ""

msgid "Pods"
msgstr ""

Expand Down Expand Up @@ -245,12 +248,18 @@ msgstr ""
msgid "Secrets"
msgstr ""

msgid "Section"
msgstr ""

msgid "Services"
msgstr ""

msgid "Settings"
msgstr ""

msgid "Shared Folders"
msgstr ""

msgid "Size"
msgstr ""

Expand All @@ -277,6 +286,16 @@ msgid ""
"not set, a self-signed certificate from cert-manager is used."
msgstr ""

msgid ""
"The following placeholders can be used in recipes to get access to global "
"system information and the configuration "
"database:<br><ul><li>hostname()</li><li>domain()</li><li>fqdn()</li><li>uid(name)</li><li>gid(name)</li><li>sharedfolder_path(name)</li><li>conf_get(id,"
" uuid=NULL)</li></ul>You have to denote placeholders with double-curly "
"braces. An overview of additional available filters can be found <a "
"href='https://twig.symfony.com/doc/filters/index.html' "
"target='_blank'>here</a>."
msgstr ""

msgid "The location where to store etcd on-demand snapshots."
msgstr ""

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: openmediavault-k8s\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-03-16 11:53+0100\n"
"POT-Creation-Date: 2024-03-26 18:29+0100\n"
"PO-Revision-Date: 2024-03-09 09:44+0000\n"
"Language-Team: Danish (https://app.transifex.com/openmediavault/teams/14254/da/)\n"
"MIME-Version: 1.0\n"
Expand All @@ -17,6 +17,9 @@ msgstr ""
"Language: da\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

msgid "Absolute Path"
msgstr ""

msgid "Access Modes"
msgstr ""

Expand All @@ -26,6 +29,9 @@ msgstr ""
msgid "Apply"
msgstr ""

msgid "Architecture"
msgstr ""

msgid "Available"
msgstr ""

Expand Down Expand Up @@ -199,9 +205,6 @@ msgstr ""
msgid "Persistent Volumes"
msgstr ""

msgid "Persistent Volumes of Shared Folders"
msgstr ""

msgid "Pods"
msgstr ""

Expand Down Expand Up @@ -241,12 +244,18 @@ msgstr ""
msgid "Secrets"
msgstr ""

msgid "Section"
msgstr ""

msgid "Services"
msgstr ""

msgid "Settings"
msgstr ""

msgid "Shared Folders"
msgstr ""

msgid "Size"
msgstr ""

Expand All @@ -273,6 +282,16 @@ msgid ""
"not set, a self-signed certificate from cert-manager is used."
msgstr ""

msgid ""
"The following placeholders can be used in recipes to get access to global "
"system information and the configuration "
"database:<br><ul><li>hostname()</li><li>domain()</li><li>fqdn()</li><li>uid(name)</li><li>gid(name)</li><li>sharedfolder_path(name)</li><li>conf_get(id,"
" uuid=NULL)</li></ul>You have to denote placeholders with double-curly "
"braces. An overview of additional available filters can be found <a "
"href='https://twig.symfony.com/doc/filters/index.html' "
"target='_blank'>here</a>."
msgstr ""

msgid "The location where to store etcd on-demand snapshots."
msgstr ""

Expand Down
Loading

0 comments on commit 46a52f5

Please sign in to comment.