ThePorgs/Exegol

Add a custom start command and a background option

Closed this issue · 4 comments

The needs

Hi France,

How could i start a container with the ssh server already running? ==> need a custom option for add command at start
How could i run a container without interaction ? (no & pls) ==> --restart unless-stopped

TY

Description

Hi France,

How could i start a container with the ssh server already running? ==> need a custom option for add command at start
How could i run a container without interaction ? (no & pls) ==> --restart unless-stopped

TY

Alternatives

No response

Additional context

No response

Hello, there, you'll find your answers on Exegol's documentation at https://exegol.rtfd.io/
More specifically

I dont have this files /opt/my-resources/setup/load_user_setup.sh (fresh install from a pip install exegol)
Anyway i try /root/.exegol/my-resources/setup/load_user_setup.sh without success and no load_setups.log found

See :
root@IAMPreseed:~# updatedb
root@IAMPreseed:~# locate load_user_setup.sh
/root/.exegol/my-resources/setup/load_user_setup.sh
/usr/local/exegol-docker-build/sources/exegol/skel/load_user_setup.sh
/var/lib/docker/overlay2/b8b33019ddc2a1040b738f131554bc2eb46a274e9eea9259349bfb1417049eb5/diff/root/sources/exegol/skel/load_user_setup.sh
/var/lib/docker/overlay2/d38cf67be41e4ea3c0ab2f0b7dcff9c25eb95f7e842a7faaebaf40d3d43b8a2d/diff/.exegol/skel/load_user_setup.sh
root@IAMPreseed:~# cat /root/.exegol/my-resources/setup/load_user_setup.sh
#!/bin/bash
set -e

# This script will be executed on the first startup of each new container with the "my-resources" feature enabled.
# Arbitrary code can be added in this file, in order to customize Exegol (dependency installation, configuration file copy, etc).
# It is strongly advised **not** to overwrite the configuration files provided by exegol (e.g. /root/.zshrc, /opt/.exegol_aliases, ...), official updates will not be applied otherwise.

# Exegol also features a set of supported customization a user can make.
# The /opt/supported_setups.md file lists the supported configurations that can be made easily.
service ssh start
root@IAMPreseed:~# cat /usr/local/exegol-docker-build/sources/exegol/skel/load_user_setup.sh
#!/bin/bash
set -e

# This script will be executed on the first startup of each new container with the "my-resources" feature enabled.
# Arbitrary code can be added in this file, in order to customize Exegol (dependency installation, configuration file copy, etc).
# It is strongly advised **not** to overwrite the configuration files provided by exegol (e.g. /root/.zshrc, /opt/.exegol_aliases, ...), official updates will not be applied otherwise.

# Exegol also features a set of supported customization a user can make.
# The /opt/supported_setups.md file lists the supported configurations that can be made easily.
service ssh start

root@IAMPreseed:~# locate load_setups.log
root@IAMPreseed:~#

Can you run exegol info please ?

Closing here, follow up of the issue at #135

For the no interaction part, I think you were more looking for the exegol exec command : https://exegol.readthedocs.io/en/latest/exegol-wrapper/exec.html