install-ipfcst-centos.sh 867 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. #!/bin/sh
  2. export basedir=/home/syjy/ipfcstV3
  3. chmod -R 777 $basedir
  4. cd $basedir/jdk
  5. tar -zxvf jdk-8u261-linux-x64.tar.gz
  6. if test -e /home/syjy/patch.zip
  7. then
  8. cd /home/syjy
  9. unzip -o patch.zip
  10. fi
  11. cp -f $basedir/settings/console /etc/init.d/
  12. cp -f $basedir/settings/reportquery /etc/init.d/
  13. chmod 777 /etc/init.d/console
  14. chmod 777 /etc/init.d/reportquery
  15. if test -x /usr/lib/systemd/system
  16. then
  17. cp -f $basedir/settings/console.service /usr/lib/systemd/system
  18. cp -f $basedir/settings/reportquery.service /usr/lib/systemd/system
  19. chmod 777 /usr/lib/systemd/system/console.service
  20. chmod 777 /usr/lib/systemd/system/reportquery.service
  21. systemctl daemon-reload
  22. systemctl enable console
  23. systemctl enable reportquery
  24. else
  25. chkconfig console on
  26. chkconfig reportquery on
  27. fi
  28. service console start
  29. service reportquery start
  30. echo "Installation is complete!"