Server and Folder Preparation
1 мин. чтения
🔐 Connect to the server via SSH #
- Open the terminal on your computer (Linux, macOS, or Windows with PowerShell/Terminal).
- Run the command, replacing
YOUR_SERVER_IP_ADDRESSwith your server’s IP address:
ssh root@YOUR_SERVER_IP_ADDRESS - At the first connection, confirm adding the key by typing yes and pressing Enter.
- Enter the
rootuser password if prompted.
🗂 Create a working directory for bots #
Create a folder to store your bot files and scripts:
mkdir -p /MYBOTS
Check that the folder was created and view permissions:
ls -ld /MYBOTS
⚙️ Set folder permissions #
- If you want, create a separate user to run the bot:
adduser botuser - Change the folder owner to the new user and set permissions:
chown -R botuser:botuser /MYBOTS
chmod -R 755 /MYBOTS
📦 Update the system and install basic tools #
Run the system update and install necessary packages:
apt update && apt upgrade -y
apt install -y python3 python3-pip git curl
🔍 Verify installed programs #
Check versions to make sure everything is working:
python3 --version
pip3 --version
git --version
curl --version
💡 Summary #
- You connected to the server via SSH.
- Created the
/MYBOTSfolder for bots. - Set folder permissions for the user.
- Updated the system and installed necessary tools.