N
N
Nikita Beletsky2020-11-07 19:39:33
Docker
Nikita Beletsky, 2020-11-07 19:39:33

What happened to docker for Windows 10 Home?

I'm taking a course on microservices, it involves using docker and k8s. Ingress service is used to access containers from a browser or Postman-type applications, skaffold is used to automate deployment management, and mongo is used as a database (also in a container on a computer). When I started taking the course, Docker for Windows Home was available in the form of a Docker toolbox bundled with an Oracle virtual machine, and k8s in the form of a minikube.exe file that was executed on the command line. About a week ago, when in my course they showed how to work with Next.js for the client side of the application, after creating the client deployment and making additions to the scaffold and ingress service configs, my mongo fell off. There are no errors in the code, it was obviously in docker or k8s or something else. Removing the client part of the application and restoring the configs, and even completely cleaning everything from the docker on the computer (docker system prune) did not help - the connection to the database was not established. After a lot of research, I saw the info on the docker website that they say that's it, the toolbox is no longer supported, install Docker Desktop as on pro Windows, only the version for home. No sooner said than done. Put everything you need, launched the application - everything plows and connects to the database. But now everything works in one place. Will explain. My application uses the express.js backend framework, and it has a feature for automatic error handling, that is, it can be configured so that when an error occurs, the express intercepts it and acts depending on how we configure it, and does not stupidly throw it to the console and asks you to fix the code. I have it set up like this that there are several types of specific errors, such as 404 not found, incorrect username or password, etc., in which the express sends information about them after a request to the server. That is, if I intentionally enter the wrong password, which will give an error, the express will respond from the server with exactly "wrong password". But if suddenly some unknown error appears in the application, which is not in the list of configured ones, the express will simply return "something went wrong" in the answer. So now, when manually testing requests in Postman (or in the browser through the client part, which I remade and the database didn’t fall off anymore), the server often responds to me with this “something went wrong”, and the most stupid, what is treated is simply by opening a file with the request logic that gives an error and pressing Ctrl + S (and if it doesn’t help, insert an empty console.log() somewhere in the code before saving). And how the scaffold synchronizes the file into the container, you can click and the server will respond as it should. And it also happens that once it will answer "something went wrong", and I press it a second time - it will answer as it should. As for automatic tests (we use jest), everything works without errors, from time to time all tests pass without dancing with Ctrl+S or console.log(). Explain what happened to the docker, maybe you should switch to a poppy or buy a pro Windows to install a full-fledged docker?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question