deploy: Convert remaining g_print() to systemd journal messages
These bits should be logged more sanely.
This commit is contained in:
parent
bf37a9c741
commit
78726244a0
|
|
@ -28,6 +28,8 @@
|
||||||
#include "otutil.h"
|
#include "otutil.h"
|
||||||
#include "libgsystem.h"
|
#include "libgsystem.h"
|
||||||
|
|
||||||
|
#define OSTREE_VARRELABEL_ID "da679b08acd34504b789d96f818ea781"
|
||||||
|
#define OSTREE_CONFIGMERGE_ID "d3863baec13e4449ab0384684a8af3a7"
|
||||||
#define OSTREE_DEPLOYMENT_COMPLETE_ID "dd440e3e549083b63d0efc7dc15255f1"
|
#define OSTREE_DEPLOYMENT_COMPLETE_ID "dd440e3e549083b63d0efc7dc15255f1"
|
||||||
|
|
||||||
/* FIXME when we depend on new enough libgsystem, move to
|
/* FIXME when we depend on new enough libgsystem, move to
|
||||||
|
|
@ -429,13 +431,11 @@ merge_etc_changes (GFile *orig_etc,
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (modified->len > 0 || removed->len > 0 || added->len > 0)
|
gs_log_structured_print_id_v (OSTREE_CONFIGMERGE_ID,
|
||||||
g_print ("ostadmin: Processing /etc: %u modified, %u removed, %u added\n",
|
"Copying /etc changes: %u modified, %u removed, %u added",
|
||||||
modified->len,
|
modified->len,
|
||||||
removed->len,
|
removed->len,
|
||||||
added->len);
|
added->len);
|
||||||
else
|
|
||||||
g_print ("ostadmin: No modified configuration\n");
|
|
||||||
|
|
||||||
for (i = 0; i < removed->len; i++)
|
for (i = 0; i < removed->len; i++)
|
||||||
{
|
{
|
||||||
|
|
@ -713,8 +713,9 @@ selinux_relabel_var_if_needed (OstreeSysroot *sysroot,
|
||||||
|
|
||||||
if (!g_file_query_exists (deployment_var_labeled, NULL))
|
if (!g_file_query_exists (deployment_var_labeled, NULL))
|
||||||
{
|
{
|
||||||
g_print ("ostadmin: Didn't find '%s', relabeling /var\n",
|
gs_log_structured_print_id_v (OSTREE_VARRELABEL_ID,
|
||||||
gs_file_get_path_cached (deployment_var_labeled));
|
"Relabeling /var (no stamp file '%s' found)",
|
||||||
|
gs_file_get_path_cached (deployment_var_labeled));
|
||||||
|
|
||||||
if (!selinux_relabel_dir (sysroot, sepolicy,
|
if (!selinux_relabel_dir (sysroot, sepolicy,
|
||||||
deployment_var_path, "var",
|
deployment_var_path, "var",
|
||||||
|
|
@ -834,10 +835,6 @@ merge_configuration (OstreeSysroot *sysroot,
|
||||||
cancellable, error))
|
cancellable, error))
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
g_print ("ostadmin: No previous configuration changes to merge\n");
|
|
||||||
}
|
|
||||||
|
|
||||||
ret = TRUE;
|
ret = TRUE;
|
||||||
gs_transfer_out_value (out_sepolicy, &sepolicy);
|
gs_transfer_out_value (out_sepolicy, &sepolicy);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue