Signed-off-by: Thomas Lamprecht <t.lampre...@proxmox.com> --- data/PVE/API2/ClusterConfig.pm | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-)
diff --git a/data/PVE/API2/ClusterConfig.pm b/data/PVE/API2/ClusterConfig.pm index fa01022..c38feb2 100644 --- a/data/PVE/API2/ClusterConfig.pm +++ b/data/PVE/API2/ClusterConfig.pm @@ -136,7 +136,17 @@ __PACKAGE__->register_method ({ }, }, }, - returns => { type => 'null' }, + returns => { + type => "object", + properties => { + corosync_authkey => { + type => 'string', + }, + corosync_conf => { + type => 'string', + } + }, + }, code => sub { my ($param) = @_; @@ -222,7 +232,15 @@ __PACKAGE__->register_method ({ $config_change_lock->($code); die $@ if $@; - return undef; + my $clusterconf = "/etc/pve/corosync.conf"; + my $authfile = "/etc/corosync/authkey"; + + my $res = { + corosync_authkey => PVE::Tools::file_get_contents($authfile), + corosync_conf => PVE::Tools::file_get_contents($clusterconf), + }; + + return $res; }}); -- 2.11.0 _______________________________________________ pve-devel mailing list pve-devel@pve.proxmox.com https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel