merge titanium and libre
This commit is contained in:
119
saretlinux.sh
119
saretlinux.sh
@@ -123,114 +123,7 @@ git commit --global user.email "saretbenny@gmail.com"
|
||||
git commit --global user.name "1kamma"
|
||||
git config --global user.email "saretbenny@gmail.com"
|
||||
git config --global user.name "1kamma"
|
||||
if [ "$HOST" = "libre-computer" ];
|
||||
then
|
||||
su -c 'wget -O - "https://connect.jfrog.io/install_connect" | sh -s VBr9r2byCYKNaE3rgZwYZANg8BueGk3HAQ Server'
|
||||
curl -sSL "https://www.googleapis.com/drive/v3/files/12E1DAwQaQUT7lWOs1EhTD5Xk_sAnGqjo?alt=media&key=AIzaSyCy8ppkVWYQFSznbe1SHuAITSZ-ux_ZCZk" >/home/saret/.ssh/LibreGithub
|
||||
curl -fsSL https://archive.heckel.io/apt/pubkey.txt | sudo gpg --armor --keyring gnupg-ring:/etc/apt/trusted.gpg.d/archive.heckel.io.gpg --no-default-keyring --import
|
||||
tee /etc/apt/sources.list.d/archive.heckel.io.list <<EOF
|
||||
deb https://archive.heckel.io/apt debian main
|
||||
deb-src https://archive.heckel.io/apt debian main
|
||||
EOF
|
||||
sudo apt update
|
||||
sudo apt install ntfy
|
||||
#sudo systemctl enable ntfy
|
||||
#sudo systemctl start ntfy
|
||||
tee /home/saret/.ssh/config <<EOF
|
||||
Host GitHub
|
||||
Hostname ssh.github.com
|
||||
Port 443
|
||||
User git
|
||||
IdentityFile ~/.ssh/LibreGithub
|
||||
|
||||
Host gist
|
||||
Hostname gist.github.com
|
||||
User git
|
||||
IdentityFile ~/.ssh/LibreGithub
|
||||
EOF
|
||||
sudo tee /etc/systemd/system/RunSSH.service <<EOF
|
||||
[Unit]
|
||||
Description=Run This SSH in ssh-j server
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
Restart=always
|
||||
RestartSec=3600
|
||||
ExecStart=/Scripts/ssh.sh
|
||||
User=saret
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
sudo chmod a+x /etc/systemd/system/RunSSH.service
|
||||
sudo mkdir /Scripts
|
||||
sudo tee /Scripts/ssh.sh <<EOF
|
||||
if [[ "\$(ps -x |grep saret@ssh |awk '{print \$9}')" != *"libre-computer:22:localhost:22"* ]]; then
|
||||
ssh saret@ssh-j.com -N -R libre-computer:22:localhost:22
|
||||
fi
|
||||
EOF
|
||||
sudo chmod a+x /Scripts/ssh.sh
|
||||
sudo tee /Scripts/update_data <<EOF
|
||||
#!/bin/bash
|
||||
apt -y update
|
||||
EOF
|
||||
sudo chmod a+x /Scripts/update_data
|
||||
sudo tee /nan <<EOF
|
||||
# Edit this file to introduce tasks to be run by cron.
|
||||
#
|
||||
# Each task to run has to be defined through a single line
|
||||
# indicating with different fields when the task will be run
|
||||
# and what command to run for the task
|
||||
#
|
||||
# To define the time you can provide concrete values for
|
||||
# minute (m), hour (h), day of month (dom), month (mon),
|
||||
# and day of week (dow) or use '*' in these fields (for 'any').
|
||||
#
|
||||
# Notice that tasks will be started based on the cron's system
|
||||
# daemon's notion of time and timezones.
|
||||
#
|
||||
# Output of the crontab jobs (including errors) is sent through
|
||||
# email to the user the crontab file belongs to (unless redirected).
|
||||
#
|
||||
# For example, you can run a backup of all your user accounts
|
||||
# at 5 a.m every week with:
|
||||
# 0 5 * * 1 tar -zcf /var/backups/home.tgz /home/
|
||||
#
|
||||
# For more information see the manual pages of crontab(5) and cron(8)
|
||||
#
|
||||
# m h dom mon dow command
|
||||
|
||||
0 4 * * * /Scripts/update_data
|
||||
EOF
|
||||
sudo crontab /nan
|
||||
sudo tee /etc/systemd/system/GoogleDrive.service <<EOF
|
||||
[Unit]
|
||||
Description=Run Google drive folder, and mount it.
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStart=google-drive-ocamlfuse ~/GoogleDrive/
|
||||
User=saret
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
sudo chmod a+x /etc/systemd/system/GoogleDrive.service
|
||||
sudo systemctl enable GoogleDrive
|
||||
sudo systemctl enable RunSSH
|
||||
cat <<EOF >> .zshrc
|
||||
#My alias
|
||||
alias fuck="sudo apt install -y"
|
||||
alias go="sudo apt -y"
|
||||
alias no="sudo -s"
|
||||
alias dl="youtube-dl -f '(mp4,mkv)bestvideo[height>=720]+bestaudio/bestvideo[height>=720]' -o '%(title)s'"
|
||||
alias DL="youtube-dl -f '(mp4,mkv)bestvideo[height>720]+bestaudio/bestvideo[height>720]' -o '%(title)s'"
|
||||
export DOTNET_ROOT=\$HOME/.dotnet
|
||||
export PATH=\$PATH:\$HOME/.dotnet
|
||||
EOF
|
||||
elif [ "$HOST" = "tritium-h5" ]; then
|
||||
if [ "$HOST" = "tritium-h5" || "$HOST" = "libre-computer" ]; then
|
||||
curl -sSL "https://www.googleapis.com/drive/v3/files/12E1DAwQaQUT7lWOs1EhTD5Xk_sAnGqjo?alt=media&key=AIzaSyCy8ppkVWYQFSznbe1SHuAITSZ-ux_ZCZk" >/home/saret/.ssh/LibreGithub
|
||||
su -c 'wget -O - "https://connect.jfrog.io/install_connect" | sh -s VBr9r2byCYKNaE3rgZwYZANg8BueGk3HAQ Server'
|
||||
curl -fsSL https://archive.heckel.io/apt/pubkey.txt | sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/archive.heckel.io.gpg
|
||||
@@ -253,6 +146,16 @@ Host gist
|
||||
Hostname gist.github.com
|
||||
User git
|
||||
IdentityFile ~/.ssh/LibreGithub
|
||||
|
||||
Host oracle
|
||||
HostName xmpp.saret.tk
|
||||
User saret
|
||||
IdentityFile ~/.ssh/LibreSSH
|
||||
|
||||
Host neworacle
|
||||
HostName files.saret.tk
|
||||
User saret
|
||||
IdentityFile ~/.ssh/LibreSSH
|
||||
EOF
|
||||
sudo tee /etc/systemd/system/RunSSH.service <<EOF
|
||||
[Unit]
|
||||
|
Reference in New Issue
Block a user