diff options
| author | Nicholas Rodrigues Lordello <[email protected]> | 2026-05-15 09:06:50 +0200 |
|---|---|---|
| committer | Nicholas Rodrigues Lordello <[email protected]> | 2026-05-15 09:06:50 +0200 |
| commit | 795342c5e7793b66c44e8482ec7dcd94bf4f8885 (patch) | |
| tree | f04ce612b0a3a3e67b6e60627f979205cd2af6e7 /dbx-create | |
| parent | 5a07d783ba5ba3e0e10dfcda140761e865c5673f (diff) | |
Fix Image and DBX Commandsmacos
Diffstat (limited to 'dbx-create')
| -rwxr-xr-x | dbx-create | 45 |
1 files changed, 9 insertions, 36 deletions
@@ -3,42 +3,15 @@ set -euo pipefail -R="$(dirname "$(realpath "${BASH_SOURCE[0]}")")" C="dbx" -echo "TODO:" -echo "- create temporary SSH key" -echo "- generate SSH configuration for host and guest" -echo "- create base container image" -echo " - initialize user" -echo " - add authorized keys for SSH login" -echo " - install required packages (sshd and tini)" -echo " - install nice to have packages (see toolbox image)" -echo " - setup socket cleanup with sshd_config" -echo "- magic encantation to create container" +if ! container system status &>/dev/null; then + container system start +fi -#if ! id $DBX_USER &>/dev/null; then -# useradd \ -# --comment "$DBX_USER_COMMENT" \ -# --create-home \ -# --groups sudo \ -# --shell /usr/bin/bash \ -# --uid 1000 \ -# --user-group \ -# $DBX_USER -#fi -# if container list --all | grep $C >/dev/null; then -# echo "already created" -# exit -# fi -# podman create \ -# --hostname dbx \ -# --label manager=dbx \ -# --name "$c" \ -# --user root:root \ -# --userns keep-id \ -# --volume "$d:$d:z" \ -# --volume "$r/dbx-init:/usr/local/bin/dbx-init:ro,z" \ -# registry.fedoraproject.org/fedora-toolbox:43 \ -# dbx-init "$(id -u)" "$(id -g)" -# podman start "$c" >/dev/null +if container list --all | grep $C >/dev/null; then + echo "already created" + exit +fi + +container create --name $C --publish 4222:22 $C |
