This commit is contained in:
Ciro Santilli
2022-03-10 22:37:51 +00:00
parent a5be602793
commit b43b3b45f3
9 changed files with 171 additions and 73 deletions

View File

@@ -473,6 +473,14 @@ pre{ white-space:pre }
<p>This just counts every second forever and does not give you a shell.</p>
</div>
<div class="paragraph">
<p>And to pass command line arguments to the program, you can use <code>--kernel-cli-after-dash</code>:</p>
</div>
<div class="literalblock">
<div class="content">
<pre>./run --kernel-cli 'init=/bin/sh' --kernel-cli-after-dash '-c "echo asdf; pwd; ls"'</pre>
</div>
</div>
<div class="paragraph">
<p>This method is not very flexible however, as it is hard to reliably pass multiple commands and command line arguments to the init with it, as explained at: <a href="init-environment.html">Section 7.4, &#8220;Init environment&#8221;</a>.</p>
</div>
<div class="paragraph">