this script is to schedule InstyPy scripts
First, Download InstyPy and this repository
git clone https://github.com/timgrossmann/InstaPy.git
git clone https://github.com/HenryTabima/node-instagram-bot.git
Open the porject folder and install dependencies
with npm:
npm install
with yarn:
yarn install
module.exports = {
instaPyPath: 'paht/to/your/InstaPy/copy',
regExp: /\bclient-\w+\.py/,
isLogging: true
}
write the path to your InstaPy's folder in instaPyPath.
regExp is to find the InstaPy's scripts. for this example, I used a regular expression that matches with client-*.py
where * is any word (for example: client-user1.py)
To ensure that de bot is always running use PM2
With yarn:
yarn global add pm2
With npm:
npm install pm2 -g
pm2 start index.js --name instagram-bot
PD: if you want to start pm2 daemon on system's restart, you have to run once pm2 startup