Skip to content

Commit

Permalink
66
Browse files Browse the repository at this point in the history
  • Loading branch information
MrDoobPG authored and MrDoobPG committed Sep 11, 2019
1 parent 6a326ad commit e45e15f
Show file tree
Hide file tree
Showing 3 changed files with 92 additions and 14 deletions.
41 changes: 40 additions & 1 deletion menu/dependency/dependency.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,45 @@
- { package: 'python-lxml' }
- { package: 'acl' }


# apt:
# name:
# - fuse
# - nano
# - fail2ban
# - wget
# - lsb-release
# - figlet
# - update-notifier-common
# - software-properties-common
# - unzip
# - glances
# - python-pip
# - python3-pip
# - python-passlib
# - zip
# - curl
# - man-db
# - htop
# - openssh-server
# - dirmngr
# - npm
# - zip
# - apt-transport-https
# - ca-certificates
# - tree
# - ncdu
# - ctop
# - dialog
# - dnsutils
# - mc
# - apache2-utils
# - lsof
# - pwgen
# - gawk
# - python-lxml
# - acl
# - bc
- name: Update pip packages for python3
pip:
name:
Expand All @@ -68,4 +107,4 @@
- netaddr
- lxml
state: latest
executable: pip2
executable: pip2
40 changes: 39 additions & 1 deletion menu/dependency/dependencydeb.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,44 @@
- python-lxml
- acl
- bc
# New ansible way of doing this, this should replace old method soon.
# apt:
# name:
# - fuse
# - nano
# - fail2ban
# - wget
# - lsb-release
# - figlet
# - software-properties-common
# - unrar
# - unzip
# - glances
# - python-pip
# - python3-pip
# - python-passlib
# - zip
# - curl
# - man-db
# - htop
# - openssh-server
# - dirmngr
# - zip
# - apt-transport-https
# - ca-certificates
# - tree
# - ncdu
# - ctop
# - dialog
# - dnsutils
# - mc
# - apache2-utils
# - lsof
# - pwgen
# - gawk
# - python-lxml
# - acl
# - bc

- name: Update pip packages for python3
pip:
Expand All @@ -71,4 +109,4 @@
- lxml
- docker
state: latest
executable: pip2
executable: pip2
25 changes: 13 additions & 12 deletions menu/functions/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,10 @@ updateprime() {
file="${abc}/new.install"
if [ ! -e "$file" ]; then newinstall; fi

ospgdistro=$(lsb_release -is)
ospgrelease=$(lsb_release -sr | cut -d. -f1)
if [[ "$ospgdistro" = "Debian" ]] && [[ "$ospgrelease" = "9" ]] || [[ "$ospgrelease" = "10" ]]; then
echo "Debian" >${abc}/os.version
else echo "Ubuntu" >${abc}/os.version; fi
ospgversion=$(cat /etc/*-release | grep Debian | grep 9)
if [ "$ospgversion" != "" ]; then
echo "debian" >${abc}/os.version
else echo "ubuntu" >${abc}/os.version; fi

echo "3" >${abc}/pg.mergerinstall
echo "52" >${abc}/pg.pythonstart
Expand Down Expand Up @@ -244,7 +243,7 @@ mergerinstall() {
elif [ "$deb10check" != "" ]; then
activated=true
echo "deb10" >/var/plexguide/mergerfs.version
wget "https://github.com/trapexit/mergerfs/releases/download/2.28.1/mergerfs_2.28.1.debian-buster_amd64.deb"
wget "https://github.com/trapexit/mergerfs/releases/download/2.28.1/mergerfs_2.28.1.debian-buster_amd64.deb"

elif [ "$activated" != "true" ]; then
activated=true && echo "ub18 - but didn't detect correctly" >/var/plexguide/mergerfs.version
Expand All @@ -264,7 +263,7 @@ mergerinstall() {
tee <<-EOF
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
↘️ MergerFS has been updated! Requires PG Clone redeployment.
↘️ MergerFS has been updated! Requires Clone redeployment.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
INFORMATION: MergerFS was updated on your system and brings performance improvements!
Expand Down Expand Up @@ -297,15 +296,17 @@ mountcheck() {
}

localspace() {
ansible-playbook /opt/pgui/pgui.yml
ansible-playbook /opt/plexguide/menu/pgui/localspace.yml
}
gtused() {
ansible-playbook /opt/plexguide/menu/pgui/gtused.yml
}

tee <<-EOF
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
↘️ User Interface Installed / Updated
↘️ User Interface (PGUI) Installed / Updated
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
INFORMATION: PGUI is a simple interface that provides information,
Expand Down Expand Up @@ -429,7 +430,7 @@ pythonstart() {

dockerinstall() {
ospgversion=$(cat /var/plexguide/os.version)
if [ "$ospgversion" == "Debian" ]; then
if [ "$ospgversion" == "debian" ]; then
ansible-playbook /opt/plexguide/menu/pg.yml --tags dockerdeb
else
ansible-playbook /opt/plexguide/menu/pg.yml --tags docker
Expand Down Expand Up @@ -464,7 +465,7 @@ serverid() {
tee <<-EOF
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
↘️ Establishing Server ID 💬 Use One Word & Keep it Simple
↘️ Establishing Server ID 💬 Use One Word & Keep it Simple
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
EOF
read -p '🌏 TYPE Server ID | Press [ENTER]: ' typed </dev/tty
Expand Down Expand Up @@ -504,7 +505,7 @@ watchtower() {
tee <<-EOF
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
📂 PG WatchTower Edition
📂 WatchTower Edition
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
💬 WatchTower updates your containers soon as possible!
Expand Down Expand Up @@ -559,4 +560,4 @@ watchtowergen() {
echo -n $p >>/tmp/watchtower.set
echo -n " " >>/tmp/watchtower.set
done </var/plexguide/app.list
}
}

0 comments on commit e45e15f

Please sign in to comment.