mirror of
https://github.com/parchlinux/calamares.git
synced 2025-06-28 09:55:37 -04:00
[machineid] Implement systemd machine-id creation
This commit is contained in:
parent
2b9e1d6231
commit
145855a56f
1 changed files with 8 additions and 1 deletions
|
@ -142,7 +142,14 @@ createEntropy( const EntropyGeneration kind, const QString& rootMountPoint, cons
|
||||||
Calamares::JobResult
|
Calamares::JobResult
|
||||||
createSystemdMachineId( const QString& rootMountPoint, const QString& fileName )
|
createSystemdMachineId( const QString& rootMountPoint, const QString& fileName )
|
||||||
{
|
{
|
||||||
return Calamares::JobResult::internalError( QObject::tr( "Internal Error" ), QObject::tr( "Not implemented" ), 0 );
|
auto cmd = QStringList { QStringLiteral( "systemd-machine-id-setup" ) };
|
||||||
|
auto r = CalamaresUtils::System::instance()->targetEnvCommand( cmd );
|
||||||
|
if ( r.getExitCode() )
|
||||||
|
{
|
||||||
|
return r.explainProcess( cmd, std::chrono::seconds( 0 ) );
|
||||||
|
}
|
||||||
|
|
||||||
|
return Calamares::JobResult::ok();
|
||||||
}
|
}
|
||||||
|
|
||||||
Calamares::JobResult
|
Calamares::JobResult
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue