Skip to content
Permalink
Browse files

Fix order of scripts for Pi Zero

  • Loading branch information...
NEMS Linux
NEMS Linux committed Feb 17, 2019
1 parent 7981eca commit 895bc6546c426ee8cafa39b27f1f9dcb06d2b2b5
Showing with 25 additions and 16 deletions.
  1. +22 −0 build/000-nems-scripts
  2. +3 −1 build/{154-php72 → 036-php72}
  3. +0 −15 build/150-nems
@@ -0,0 +1,22 @@
#!/bin/bash

if [[ ! -d /usr/local/share/nems ]]; then
mkdir /usr/local/share/nems
fi

cd /usr/local/share/nems
git clone https://github.com/Cat5TV/nems-scripts

# Add base symlinks for NEMS commands
ln -sf /usr/local/share/nems/nems-scripts/benchmark.sh /usr/local/bin/nems-benchmark
ln -sf /usr/local/share/nems/nems-scripts/gen-cert.sh /usr/local/bin/nems-cert
ln -sf /usr/local/share/nems/nems-scripts/info.sh /usr/local/bin/nems-info
ln -sf /usr/local/share/nems/nems-scripts/init.sh /usr/local/bin/nems-init
ln -sf /usr/local/share/nems/nems-scripts/mailtest.sh /usr/local/bin/nems-mailtest
ln -sf /root/nems/nems-admin/nems-push.sh /usr/local/bin/nems-push
ln -sf /usr/local/share/nems/nems-scripts/quickfix.sh /usr/local/bin/nems-quickfix
ln -sf /root/nems/nems-migrator/restore.sh /usr/local/bin/nems-restore
ln -sf /usr/local/share/nems/nems-scripts/update.sh /usr/local/bin/nems-update
ln -sf /usr/local/share/nems/nems-scripts/upgrade.sh /usr/local/bin/nems-upgrade


@@ -1,5 +1,8 @@
#!/bin/bash

# Get the platform before removing php (as it requires PHP)
platform=$(/usr/local/bin/nems-info platform)

# Uninstall PHP 7.0 residual packages
apt remove --purge -y php7.0-cli
apt remove --purge -y php7.0-common
@@ -12,7 +15,6 @@ apt -y autoremove
# Install PHP 7.2

# Use Raspbian repo for Pi, Sury's Debian Repo for others.
platform=$(/usr/local/bin/nems-info platform)
if [[ $platform = "0" ]] ||
[[ $platform = "1" ]] ||
[[ $platform = "2" ]] ||
@@ -48,21 +48,6 @@ git clone https://github.com/Cat5TV/nconf && chown -R www-data:www-data nconf
cp -f /root/nems/nems-migrator/data/1.4/nconf/mysql.php /var/www/nconf/config/
cp -f /root/nems/nems-migrator/data/1.4/nconf/nconf.php /var/www/nconf/config/

cd /usr/local/share/nems
git clone https://github.com/Cat5TV/nems-scripts

# Add base symlinks for NEMS commands
ln -sf /usr/local/share/nems/nems-scripts/benchmark.sh /usr/local/bin/nems-benchmark
ln -sf /usr/local/share/nems/nems-scripts/gen-cert.sh /usr/local/bin/nems-cert
ln -sf /usr/local/share/nems/nems-scripts/info.sh /usr/local/bin/nems-info
ln -sf /usr/local/share/nems/nems-scripts/init.sh /usr/local/bin/nems-init
ln -sf /usr/local/share/nems/nems-scripts/mailtest.sh /usr/local/bin/nems-mailtest
ln -sf /root/nems/nems-admin/nems-push.sh /usr/local/bin/nems-push
ln -sf /usr/local/share/nems/nems-scripts/quickfix.sh /usr/local/bin/nems-quickfix
ln -sf /root/nems/nems-migrator/restore.sh /usr/local/bin/nems-restore
ln -sf /usr/local/share/nems/nems-scripts/update.sh /usr/local/bin/nems-update
ln -sf /usr/local/share/nems/nems-scripts/upgrade.sh /usr/local/bin/nems-upgrade

# Create symlinks, apply patches/fixes, etc.
/usr/local/share/nems/nems-scripts/fixes.sh

0 comments on commit 895bc65

Please sign in to comment.
You can’t perform that action at this time.