Installing Python bots and scripts on the server |
Installing Python bots and scripts on the server Today we will tell you how to install a bot on a dedic with an Ubuntu ( Linux) system Some abbreviations: 1. Which service should I choose? Minimum tariff: Features: OS selection: Ubuntu, Debian, CentOS, Alma, Rocky, Astra, FreeBSD (Windows Server, Windows — not at the minimum rate) Minimum tariff: Tech support did not respond, let's fire the dude | 1 Core | 2.8 GHz Features: GPT Support - it works crookedly, but if you formulate the question correctly, it will answer the topic. Its own Configuration - you can choose your own server characteristics without unnecessary Disk space, for example. OS selection: Ubuntu, Debian, CentOS, BitrixVM + CentOS, Astra Linux CE, AlmaLinux, Arch Linux, BrainyCP + Ubuntu I used Aeza and TimeWeb, but at the moment I use TimeWeb and everything is fine. The rest of the services were used, but they were not successful or incompetent support 2. Purchase of a server 1. The image 2. Region 3. Configuration 4. Also other settings 5. Conclusion on setting up Well, then we choose the payment method and pay for the server. 3. Setting up the server 4. Setting up the server Installing the program 1. Setting up And click Log In from below If you have successfully connected, you will see buttons on the left. We are interested in New Terminal Console ( for working with commands and startup) and New Windows SFTP ( for working with files ): Go to SFTP ( file manager with our server ) and transfer the script file or folder A file or folder can be moved to the right block of Remote files. Note that you must be located in the /root directory 2. Launch
After completing the command, we check whether your file is on the disk with the ls command If the file has been moved and everything is OK, then move on We prescribe the command
This text greets us and we press Enter If this is a folder such as script, then go to the directory
If this is a script, then we set the necessary settings, if you don't know, we won't check it yet python 3 script.py As we observe the error.
After that, also run the file until it starts correctly, or until the same error occurs and install these dependencies And close the screen by pressing Ctrl + A + D To return to the screen, we prescribe
In this case, you need to use v env, which we installed with the first command. We install two commands:
After that, we repeat the installation of dependencies and run the script Go back |
3-08-2024, 02:24 |