📜 ⬆️ ⬇️

The harsh web development market in Russia or why do we need databases, persistent storage and FTP

image


What would the child not indulge, if only FTP does not deploy and scale its products, pumping images of virtual machines. Respect and praise to smart guys and girls who know what CI, CD is and actively use them in their production. Cust Dev in Russia showed that everything is very bad. Alas.

Cry from the heart


We observe anonymity and hope not to offend anyone. To the question “How do you work and deliver your product in production?” We heard a lot of different answers. Here are some theses from the most popular answers:
  1. I do not use ide, I do everything through the WordPress admin panel, handles opening files from the ftp file in the sublime.
  2. We deploy new instances of your SaaS, copying the entire virtuals. Overnight copied normally.
  3. How how? On ftp, and git we use for backup copies.
  4. We planned to use git, but somehow it didn't work out. Now all hands.
  5. I have everything set up with the help of capistrano.
  6. All through pull requests, then a severe code review, then CI pulls everything up in the prod.


These are not spherical horses in a vacuum, but real people from real studios and agencies of Russia from large and small cities. Surprisingly, differences in the relative shares of a particular response depending on the region turned out to be insignificant. Perhaps for a small and frivolous project, such as a one-page site, this approach is quite reasonable, but if you are responsible for DevOps in a more or less large web studio, it is simply vital to stick to git workflow and use a number of CI / / for painless scaling. CD tools.
')

SaaS scaling


Everyone has their own pain, and how to use this or that tool is decided by everyone. If you are a happy owner of SaaS solutions (monitoring systems, CRM, CMS, in general, everything where you need to scale quickly horizontally) and you still clone virtual machines, then God will help you. Write to us in the support, and we will offer you favorable conditions for using our platform to ensure rapid scaling. A small demo of such an applied use of our system



Misuse of the system, permanent storage and FTP


There is what is, and it is necessary to work with it. The features of the Docker images and containers include certain restrictions for file operations inside the container, namely, non-persistence of the result of their execution after restarting the web server process (which causes the container to be re-created) or restart your application image. We, though indirectly, are a Shared CaaS solution. Our offer is a repository with FTP access from the outside. The folder is mounted in the container when building and launching the application.

For those who like to write php systems on the template system, this problem is most relevant, for 90% of the written solutions godlessly create a lot of file operations, save data, configs, themes, settings, etc. If you take the example of running a web server that is compatible with most php systems (the availability of Apache is simply necessary for many) https://github.com/dokkur/php-common/blob/master/Procfile , then we in the simplest version make it possible to drop all the necessary content into the mounted folder via FTP. For this you need:
  1. Register with us
  2. Press the + button at the top right
  3. Enter the application name, select the data center
  4. Select a template you need - Any PHP
  5. Wait until the application is created, go to the Storage menu.
  6. Click on the / app / www line and get the connection data: Host, Username, Password. If the DNS changes have not yet overtaken your site or if you have cached something else there, then we recommend using the domain name of the instance on which your application is created: in the Settings menu, look at the git url and read the hostname - what’s between the characters “@” And “:”.

I emphasize that we are far from such an approach in development, so we will be extremely grateful for your feedback on this flow - what is needed, what is not needed.

What to do and who is to blame?


Blame it all for a little bit no one to blame and what to do, everyone decides for himself.

If you are a developer and you are interested in your professional growth, we will be happy to advise you on working with git, build packs, help you find the optimal production configuration of your application. Support is always at your service.

If you have your own project and you have certain difficulties in the work / production setting or just want to optimize the deployment of your project, do everything according to the mind, adjust the scaling, be confident in fault tolerance, we are ready to help you with the move to us and along the way we will complete audit your architecture.

Source: https://habr.com/ru/post/303388/


All Articles