|
3 | 3 |
|
4 | 4 | # Symlink each category into a data folder in the root of this git repo
|
5 | 5 | #chmod +x scripts/*
|
6 |
| -ln -s ~/derp/actions ~/homelab_status_page/data/actions |
7 |
| -ln -s ~/derp/cartoons ~/homelab_status_page/data/cartoons |
8 |
| -ln -s ~/derp/comics ~/homelab_status_page/data/comics |
9 |
| -ln -s ~/derp/embeddings ~/homelab_status_page/data/embeddings |
10 |
| -ln -s ~/derp/intermediate_representation ~/homelab_status_page/data/intermediate_representation |
11 |
| -ln -s ~/derp/logs ~/homelab_status_page/data/logs |
| 6 | +# ln -s ~/derp/actions ~/homelab_status_page/data/actions |
| 7 | +# ln -s ~/derp/cartoons ~/homelab_status_page/data/cartoons |
| 8 | +# ln -s ~/derp/comics ~/homelab_status_page/data/comics |
| 9 | +# ln -s ~/derp/embeddings ~/homelab_status_page/data/embeddings |
| 10 | +# ln -s ~/derp/intermediate_representation ~/homelab_status_page/data/intermediate_representation |
| 11 | +# ln -s ~/derp/logs ~/homelab_status_page/data/logs |
12 | 12 |
|
13 |
| -ln -s ~/derp/sensor_data ~/homelab_status_page/data/sensor_data |
| 13 | +# ln -s ~/derp/sensor_data ~/homelab_status_page/data/sensor_data |
14 | 14 |
|
15 | 15 | #!/bin/bash
|
16 | 16 |
|
17 | 17 | # Script to clone and build specified Jetson containers
|
18 | 18 |
|
19 | 19 | # Check if Git is installed
|
20 |
| -if ! command -v git &> /dev/null |
21 |
| -then |
22 |
| - echo "Git is not installed. Please install Git before running this script." |
23 |
| - exit |
24 |
| -fi |
25 |
| - |
26 |
| -# Check if Docker is installed |
27 |
| -if ! command -v docker &> /dev/null |
28 |
| -then |
29 |
| - echo "Docker is not installed. Please install Docker before running this script." |
30 |
| - exit |
31 |
| -fi |
32 |
| - |
33 |
| -# Clone or update the jetson-containers repository |
34 |
| -if [ ! -d "jetson-containers" ]; then |
35 |
| - echo "Cloning jetson-containers repository..." |
36 |
| - git clone https://github.com/dusty-nv/jetson-containers.git |
37 |
| -else |
38 |
| - echo "Updating jetson-containers repository..." |
39 |
| - cd jetson-containers |
40 |
| - git pull |
41 |
| - cd .. |
42 |
| -fi |
43 |
| - |
44 |
| -cd jetson-containers |
| 20 | +# if ! command -v git &> /dev/null |
| 21 | +# then |
| 22 | +# echo "Git is not installed. Please install Git before running this script." |
| 23 | +# exit |
| 24 | +# fi |
| 25 | + |
| 26 | +# # Check if Docker is installed |
| 27 | +# if ! command -v docker &> /dev/null |
| 28 | +# then |
| 29 | +# echo "Docker is not installed. Please install Docker before running this script." |
| 30 | +# exit |
| 31 | +# fi |
| 32 | + |
| 33 | +# # Clone or update the jetson-containers repository |
| 34 | +# if [ ! -d "jetson-containers" ]; then |
| 35 | +# echo "Cloning jetson-containers repository..." |
| 36 | +# git clone https://github.com/dusty-nv/jetson-containers.git |
| 37 | +# else |
| 38 | +# echo "Updating jetson-containers repository..." |
| 39 | +# cd jetson-containers |
| 40 | +# git pull |
| 41 | +# cd .. |
| 42 | +# fi |
| 43 | + |
| 44 | + |
| 45 | +#cd jetson-containers |
45 | 46 |
|
46 | 47 | # List of package paths
|
47 |
| -packages=( |
48 |
| - "packages/llm/ollama" |
49 |
| - "packages/llm/llama_cpp" |
50 |
| - "packages/llm/llama-factory" |
51 |
| - "packages/llm/exllama" |
52 |
| - "packages/vlm/llama-vision" |
53 |
| -) |
54 |
| - |
55 |
| -# Build each container |
56 |
| -for package in "${packages[@]}"; do |
57 |
| - echo "-----------------------------------------" |
58 |
| - echo "Building container for $package" |
59 |
| - cd "$package" |
60 |
| - |
61 |
| - # Check if a build script exists |
62 |
| - if [ -f "build.sh" ]; then |
63 |
| - echo "Found build.sh, executing..." |
64 |
| - chmod +x build.sh |
65 |
| - ./build.sh |
66 |
| - elif [ -f "Dockerfile" ]; then |
67 |
| - # Build the Docker image |
68 |
| - image_name="${package##*/}" |
69 |
| - echo "No build.sh found. Building Docker image: $image_name" |
70 |
| - docker build -t "$image_name" . |
71 |
| - else |
72 |
| - echo "No build script or Dockerfile found in $package. Skipping..." |
73 |
| - fi |
74 |
| - |
75 |
| - cd - > /dev/null |
76 |
| -done |
77 |
| - |
78 |
| -echo "All containers have been built." |
| 48 | +# packages=( |
| 49 | +# "packages/llm/ollama" |
| 50 | +# "packages/llm/llama_cpp" |
| 51 | +# "packages/llm/llama-factory" |
| 52 | +# "packages/llm/exllama" |
| 53 | +# "packages/vlm/llama-vision" |
| 54 | +# ) |
| 55 | + |
| 56 | +# # Build each container |
| 57 | +# for package in "${packages[@]}"; do |
| 58 | +# echo "-----------------------------------------" |
| 59 | +# echo "Building container for $package" |
| 60 | +# cd "$package" |
| 61 | + |
| 62 | +# # Check if a build script exists |
| 63 | +# if [ -f "build.sh" ]; then |
| 64 | +# echo "Found build.sh, executing..." |
| 65 | +# chmod +x build.sh |
| 66 | +# ./build.sh |
| 67 | +# elif [ -f "Dockerfile" ]; then |
| 68 | +# # Build the Docker image |
| 69 | +# image_name="${package##*/}" |
| 70 | +# echo "No build.sh found. Building Docker image: $image_name" |
| 71 | +# docker build -t "$image_name" . |
| 72 | +# else |
| 73 | +# echo "No build script or Dockerfile found in $package. Skipping..." |
| 74 | +# fi |
| 75 | + |
| 76 | +# cd - > /dev/null |
| 77 | +# done |
| 78 | + |
| 79 | +# echo "All containers have been built." |
79 | 80 |
|
80 | 81 | # https://github.com/dusty-nv/jetson-inference
|
81 | 82 |
|
@@ -508,30 +509,7 @@ echo "All containers have been built."
|
508 | 509 |
|
509 | 510 |
|
510 | 511 | # Function to install and run Portainer
|
511 |
| -install_portainer() { |
512 |
| - # Update package list and install dependencies |
513 |
| - sudo apt-get update |
514 |
| - sudo apt-get install -y docker.io |
515 |
| - |
516 |
| - # Pull the latest Portainer image |
517 |
| - sudo docker pull portainer/portainer-ce:latest |
518 |
| - |
519 |
| - # Create a Docker volume for Portainer data |
520 |
| - sudo docker volume create portainer_data |
521 |
| - |
522 |
| - # Run Portainer container |
523 |
| - sudo docker run -d \ |
524 |
| - --name=portainer \ |
525 |
| - --restart=always \ |
526 |
| - -p 8000:8000 \ |
527 |
| - -p 9443:9443 \ |
528 |
| - -v /var/run/docker.sock:/var/run/docker.sock \ |
529 |
| - -v portainer_data:/data \ |
530 |
| - portainer/portainer-ce:latest |
531 |
| - |
532 |
| - echo "Portainer installation and setup completed." |
533 |
| -} |
534 |
| - |
| 512 | +# l |
535 | 513 |
|
536 | 514 |
|
537 | 515 | # Call the functions to install Portainer and configure Caddy
|
|
0 commit comments