From 0c43f905d06d5b4b0d5a54a435b7e109e0a44071 Mon Sep 17 00:00:00 2001 From: mik-tf Date: Fri, 8 Nov 2024 12:59:09 -0500 Subject: [PATCH] simplified docker steps --- hero_docs/crystallib_hero_basic_docs.md | 25 +++++-------------------- 1 file changed, 5 insertions(+), 20 deletions(-) diff --git a/hero_docs/crystallib_hero_basic_docs.md b/hero_docs/crystallib_hero_basic_docs.md index af82417..7188e41 100644 --- a/hero_docs/crystallib_hero_basic_docs.md +++ b/hero_docs/crystallib_hero_basic_docs.md @@ -16,36 +16,21 @@ We provide the steps to prepare a Docker Ubuntu container to work with Hero and ## Prerequisites - Docker -- Make sure that you have set your SSH Public Key on both GitHub and the TFGrid Gitea (https://git.ourworld.tf) ## Deploy Webserver - Run the Ubuntu container with host networking and a specific name ``` -sudo docker run -it --net=host --name=hero-container -v ~/dvol:/root/code ubuntu:latest /bin/bash -``` -- Create Directory .ssh in container -``` -mkdir -p ~/.ssh -``` - -- Copy SSH keys to container from local machine (use the proper path and key type) -``` -sudo docker cp ~/.ssh/id_ed25519 hero-container:/root/.ssh/id_ed25519 -sudo docker cp ~/.ssh/id_ed25519.pub hero-container:/root/.ssh/id_ed25519.pub +sudo docker run -it --net=host --name=hero-container -v ~/code:/root/code ubuntu:latest /bin/bash ``` - Execute all commands directly in the container ``` # Install prerequisites - -apt update && apt install -y git curl nano openssh-client libsqlite3-dev python3-venv - -# Set up SSH agent and add the key - -eval $(ssh-agent) -ssh-add ~/.ssh/id_ed25519 +export DEBIAN_FRONTEND=noninteractive +apt-get update -y +apt-get install -y git curl nano openssh-client libsqlite3-dev python3-venv # Clone the repository and set up the environment @@ -77,5 +62,5 @@ When you're done, you can clean up your environment. ``` sudo docker stop hero-container sudo docker rm hero-container -sudo find ~/dvol -mindepth 1 -delete +sudo find ~/code -mindepth 1 -delete ``` \ No newline at end of file -- 2.40.1