Advanced search
Evgenij LegotskojJan. 5, 2018, 2:11 a.m.

DjangoDjango - Tutorial 030. Opportunities VDS server for $ 5 for the project on Django

Ubuntu, Django, VDS

With the growth of site functionality, as well as attendance, it was possible to successfully test the capabilities of the current VDS server, which I currently use. I would like to describe my experience with VDS, as well as show how much this VDS keeps under certain conditions and sizes of the project.

I decided to tell about it right now, because a week ago I expanded the server's capacity by purchasing additional memory.

All the further narrative will be subjective, but I hope that it will make it possible to make a general picture, so that newcomers will be able to navigate in what server they need for their needs, and this will facilitate the choice of the server.

Server Configuration

Initially, the site worked on the minimum configuration that I managed to take. The fare is $5 per month. By the way, my ISP also has a cheaper tariff (190 rubles / month), but it is fixed, whereas my current tariff allows me to configure the configuration necessary for me and increase the server's capacity to one that is not available at fixed tariffs.


  1. Processor cores: 2 x 2,7 GHz
  2. RAM: 512 Mb
  3. SSD: 5Gb
  4. OS: Ubuntu 16.04
  5. Access to the Internet: 100 Mbit/s

All configuration of the server was done exclusively through the console, without any auxiliary tools like ISP Manager, which also absorbs some of the RAM, so this modest RAM was enough for me for a long time

Evgenij LegotskojJune 22, 2017, 6:17 a.m.

LinuxConfiguring HTTPS from Let`s Encrypt with Certbot

LetsEncrypt, Ubuntu, Nginx, HTTPS, SSL, HTTP

Some time ago, the SSL certificate from Let`s Encrypt ceased to be updated on the site. Judging by the mistakes, the structure of the files for organizing the keys has changed somewhat. After researching the problem, the easiest option was to install SSL certificates using the Certbot utility. This utility installs certificates in automatic mode, and automatically creates a task to update the certificate, which is based either in the cron scheduler or in systemd .

Since the site server is running on Ubuntu 16.04, the installation kit was also selected for this OS. In the case of other operating systems, Certbot also provides manuals for other systems.

If you are setting up an SSL certificate for the first time, you can use the manual on the Certbot website, if you have already configured the certificate with other utilities, for example, with the helpencrypt package without using certbot, as shown in the next article , you will probably need to do a small cleaning Before installing Certbot`a.

Evgenij LegotskojSept. 16, 2016, 1:56 p.m.

DjangoDjango - Tutorial 001. Deploying a site on Django + PostgreSQL + Gunicorn + Nginx

Ubuntu, Gunicorn, Django, PostgreSQL, Nginx

Once access to the server with Ubuntu 16.04 was set in a previous article, it is time to expand on it everything necessary for operation of the site, namely:

  • Django - framework for developing web-applications in Python;
  • PostgreSQL - SQL database;
  • Gunicorn - WSGI HTTP Python server for UNIX systems;
  • Ngnix - HTTP-server and a reverse proxy server, mail proxy server and TCP / UDP general purpose proxy;
  • Supervisor - This process manager, which greatly simplifies the management of long-running programs, such as sites that you want to automatically restart after a fall.
Evgenij LegotskojSept. 16, 2016, 1:38 a.m.

PostgreSQLCorrection database encoding of PostgreSQL from LATIN1 to UTF8

PostreSQL, UTF8, LATIN1, Ubuntu

In the process of server settings for the site, I had to face some problems. In particular, the problem of the PostgreSQL database encoding. The fact is that when you install the PostgreSQL, database templates created with the coding LATIN1, and on the Django site works, using UTF8 encoding. As a result, dropped out following error when trying to insert the data:

ERROR: encoding UTF8 does not match locale en_US Detail: The chosen LC_CTYPE setting requires encoding LATIN1.

Search for information, it was possible to find several solutions, including a solution that allows you to re-create the database template with the encoding UTF8. But Walk carefully on the symptoms of the problem.

Evgenij LegotskojSept. 14, 2016, 1:18 p.m.

LinuxInitial configuration of access to VDS at Ubuntu 16.04

Linux, VDS, Ubuntu

Because a develop the resource EVILEG, I decided to move it to the domain COM, and transfer the website from CMS Wordpress to the framework Django. With Ruby On Rails somehow it did not work out, but with the Django process has gone almost immediately.

I did not choose another hosting, and I stayed with the current hosting TIMEWEB , by the way recommend to those who have not yet decided on his future hosting VDS.

And now we go to the initial setting up access to VDS, which provides TIMEWEB.

Evgenij LegotskojFeb. 28, 2016, 10:17 a.m.

QtQt Linux - Lesson 002. Global HotKey in Linux

Ubuntu, HotKey, linux, Qt, XCB, XLib

Work with the global keyboard hot keys in Windows is a trivial task than Linux, since this has WinAPI prepared methods that do not require a large amount of code. And each hotkey is set in line ID, in which the hot key can be removed.

In Linux / Unix, which uses the graphics server is the X11, with respect to Qt must use the function to register / unregister hotkeys from XLib library, but the process has to the values ​​obtained using XCB library functionality, which is being developed as an analogue XLib library, but is more low-level and written the C programming language. As in the case of Windows, for processing in the global hotkeys Qt 5 nativeEventFilter used method. I propose to make a separate class, inherited from QAbstractNativeEventFilter for processing hotkeys and set the filter to the entire application.

To set hotkeys to be used XKeysymToKeycode (to get the keys from KeySym sequence of code) and XGrabKey (to set the hotkey).

XUngrabKey function will be used for unregistration hotkey.

Project structure

  • - the profile of the project;
  • mainwindow.h - header file of the main application window;
  • mainwindow.cpp - file source code of the main application window;
  • mainwindow.ui - file forms the main application window;
  • main.cpp - the main source file;
  • nativeeventfilter.h - header event filter file hotkeys;
  • nativeeventfilter.cpp - file source hotkeys event filter.
Evgenij LegotskojFeb. 15, 2016, 10:07 a.m.

QtQt Linux - Lesson 001. Autorun Qt application under Linux

Qt, Linux, Ubuntu, autorun, автозапуск

Let's talk about how you can add functionality in Qt application to configure startup of the application. For example, we have a settings window, and we want to make the ability to customize the dialog box Autorun application.

In contrast to the autorun in Windows , where you can use QSettings and make changes to the registry on Linux you need to create a custom executable file that will be responsible for autostart applications when a user logs into the operating system.

Say the name of the project and hence the name of the executable file will AutorunLinux , then you need to create an executable file AutorunLinux.desktop the following path:


The contents of the executable file to do the same to other startup files of other applications that are guaranteed to get the desired result. In the case of Ubuntu Linux 15.04 / 15.10 contents of the file will receive the following:

[Desktop Entry]

Let me recommend you the excellent hosting on which EVILEG is located.

For many years, Timeweb has been proving his stability.

For projects on Django I recommend VDS hosting

View Hosting

C++ - Тест 003. Условия и циклы

  • Result:57points,
  • Rating points-2

C++ - Test 001. The first program and data types

  • Result:53points,
  • Rating points-4

C++ - Test 001. The first program and data types

  • Result:60points,
  • Rating points-1
Last comments
  • t1m4
  • Jan. 23, 2021, 8:28 a.m.

Django - Tutorial 052. Redefining a User Model

Добрый день, Я вот написал в, UserAdmin) Но у меня не появилось новые поля в админке?

Django - Tutorial 001. Deploying a site on Django + PostgreSQL + Gunicorn + Nginx

Ошибка в конфиге инжинкса про статику в root последний слеш лишний путь в таком виде получается /home/user/myprojectenv/myproject/myproject//static
  • Jurij
  • Jan. 20, 2021, 1:34 p.m.

Qt/C++ - Lesson 061. Adding images to the application using the Drag And Drop method from the file manager

// Вместо отрисовки иконки и текста будем отрисовывать только одно изображение // с небольшими отступами в 5 пикселей QPixmap pix(m_model->data(index).toString()); …
  • magrif
  • Jan. 19, 2021, 12:37 p.m.

Qt Сертификация

Здравствуйте. Подскажите, оплачивать ваучер прямо в выбранном тестовом центре? Можно ли загранник предъявить? Или свой паспорт, а заполнить транслитом? А то там пишут: Your name must exactl…
  • retmas
  • Jan. 17, 2021, 4:09 a.m.

Qt/C++ - Tutorial 074. Generating pseudo-random numbers, using STD library random

Дмитрий, решает. Просто автор, видимо, не сильно озаботился изучением документации QRandomGenerator. Да и в листинге с использованием qrand вызов функции qsrand на каждой итерации цикла нав…
Now discuss on the forum

QScrollArea dynamically add QCheckBoxes

онлайн казино Пин Ап официальный сайт играть на деньги или бесплатно без регистрации

Как поменять шаг оси с числового формата на текстовый

онлайн казино Пин Ап официальный сайт играть на деньги или бесплатно без регистрации

Добавление данных в модель из textEdit

Котов писать жалко, да что поделать - приходится) Вот мне пока не шибко понятно как именно при внесении новых данных обновлять модель, как мне заставить TableView отображать обновленные дан…

AbstractListModel использование в нескольких элементах

Разобрался. Извиняюсь за беспокойство. Я просто не поставил "model." перед переменными. Делаю рефакторинг под abstractModel, раньше модель была в QML и как то прокатывала без этого. На железе уж…
© EVILEG 2015-2020
Recommend hosting TIMEWEB