sudo vi /etc/rc.local
然后在文件最后添加 命令
cd ../home/pi/musicPlayer/ //cd到执行命令的目录
node index.js //执行命令
然后执行sudo shutdown -r now重启命令查看
树莓派自启动脚本
Author: tea9
Permalink: http://tea9.github.io/post/813369763.html
License: Copyright (c) 2017-2025 CC-BY-NC-4.0 LICENSE
Slogan: Do you believe in DESTINY?