Skip to content

Commit

Permalink
Merge branch 'master' of github.com:Surveily/Images
Browse files Browse the repository at this point in the history
  • Loading branch information
Maksymilian Mazurkiewicz committed Jul 19, 2024
2 parents 0f998c3 + a36dbc1 commit b1ea1c1
Show file tree
Hide file tree
Showing 2 changed files with 80 additions and 5 deletions.
17 changes: 12 additions & 5 deletions script/desktop-24.04.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,12 @@ apt-get update
apt-get upgrade -y
apt-get install -y wireguard resolvconf vim net-tools apt-transport-https openssh-server git iperf mpv simplescreenrecorder

# Configure SSH
echo "PasswordAuthentication no" >> /etc/ssh/sshd_config

# Install Keys
mkdir -p ~/.ssh
wget -qO ~/.ssh/authorized_keys https://github.com/turowicz.keys
mkdir -p /home/$1/.ssh
wget -qO /home/$1/.ssh/authorized_keys https://github.com/turowicz.keys

# Install Docker
curl https://get.docker.com | sh && systemctl --now enable docker
Expand All @@ -47,9 +50,13 @@ curl -fsSLo /usr/share/keyrings/brave-browser-archive-keyring.gpg https://brave-
echo "deb [signed-by=/usr/share/keyrings/brave-browser-archive-keyring.gpg] https://brave-browser-apt-release.s3.brave.com/ stable main"|sudo tee /etc/apt/sources.list.d/brave-browser-release.list
apt-get update && apt-get install -y brave-browser

# Install Code
wget -O code.deb "https://code.visualstudio.com/sha/download?build=stable&os=linux-deb-x64"
dpkg -i code.deb
rm code.deb

# Configure Snap
snap remove firefox
snap install code --classic
snap install kubectl --classic
snap install helm --classic
snap install vlc
Expand All @@ -62,8 +69,8 @@ dpkg -i openlens.amd64.deb
rm openlens.amd64.deb

# Install Mainline
add-apt-repository ppa:cappelikan/ppa
apt-get update && apt-get install -y mainline
# add-apt-repository ppa:cappelikan/ppa
# apt-get update && apt-get install -y mainline

# Configure VS Code
# echo 'code --install-extension ms-vscode-remote.remote-containers' >> /home/$1/.profile
Expand Down
68 changes: 68 additions & 0 deletions script/iso-22.04.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
#!/bin/sh

# Run: curl -s https://raw.githubusercontent.com/Surveily/Images/master/script/iso-22.04.sh | sudo bash

set -e

if [ `whoami` != root ]; then
echo "Please run this script with sudo:"
echo "sudo $0 $*"
exit 1
fi

export DEBIAN_FRONTEND=noninteractive

ARCH=$(arch)
DISTRIBUTION=$(. /etc/os-release;echo $ID$VERSION_ID)

# Register NVIDIA Container Toolkit
curl -fsSL https://nvidia.github.io/libnvidia-container/gpgkey | sudo gpg --dearmor -o /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg \
&& curl -s -L https://nvidia.github.io/libnvidia-container/stable/deb/nvidia-container-toolkit.list | \
sed 's#deb https://#deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://#g' | \
sudo tee /etc/apt/sources.list.d/nvidia-container-toolkit.list

# Register NVIDIA Cuda
wget https://developer.download.nvidia.com/compute/cuda/repos/${DISTRIBUTION/./""}/${ARCH}/cuda-keyring_1.1-1_all.deb
dpkg -i cuda-keyring_1.1-1_all.deb && rm cuda-keyring_1.1-1_all.deb

# Upgrade dependencies
apt-get update && apt-get upgrade -y && apt-get install -y lsof \
iotop \
wireguard \
resolvconf \
nvme-cli \
nfs-common \
smartmontools \
iperf \
iputils-ping \
inetutils-traceroute \
lm-sensors \
net-tools \
software-properties-common \
vim \
rsync \
htop

# Uninstall unattended upgrades to prevent from unexpected updates
apt-get remove -y unattended-upgrades

# Install Docker
# curl https://get.docker.com | sh && systemctl --now enable docker

# Install Drivers
apt-get -y install --no-install-recommends cuda-drivers-535

# Install Nvidia-Docker
apt-get install -y nvidia-container-toolkit
#nvidia-ctk runtime configure --runtime=docker
#systemctl restart docker

# # Install Mainline
# add-apt-repository -y ppa:cappelikan/ppa
# apt-get install -y mainline

# # Install QEMU
# apt-get install -y qemu binfmt-support qemu-user-static
# docker run --rm --privileged multiarch/qemu-user-static --reset -p yes -c yes
# cat /proc/sys/fs/binfmt_misc/status
# cat /proc/sys/fs/binfmt_misc/qemu-aarch64

0 comments on commit b1ea1c1

Please sign in to comment.