Posts

Showing posts with the label docker

Locale nl_NL missing in docker BitBucket pipeline

Locale nl_NL missing in docker BitBucket pipeline I'm using this bitbucket-pipelines.yml file to test my application before deploying it on the servers. We're missing the nl_NL locale after installing the dependencies. We're using the following file: bitbucket-pipelines.yml bitbucket-pipelines.yml: image: php:7.2.6 pipelines: default: - step: name: PHPUnit caches: - composer script: - apt-get update && apt-get install -y unzip git zlib1g-dev libicu-dev g++ locales - locale-gen && locale-gen nl_NL - echo "nl_NL UTF-8" >> /etc/locale.gen && echo "en_EN UTF-8" >> /etc/locale.gen && echo "enUS UTF-8" >> /etc/locale.gen && echo "en_GB UTF-8" >> /etc/locale.gen - locale -a The locale -a output after installation is as following: locale -a <1s + locale -a C C.UTF-8 POSIX I did expect the nl_NL lo...

Docker container will automatically stop after “docker run -d”

Docker container will automatically stop after “docker run -d” According to tutorial I read so far, use " docker run -d " will start a container from image, and the container will run in background. This is how it looks like, we can see we already have container id. docker run -d root@docker:/home/root# docker run -d centos 605e3928cdddb844526bab691af51d0c9262e0a1fc3d41de3f59be1a58e1bd1d But if I ran " docker ps ", nothing was returned. docker ps So I tried " docker ps -a ", I can see container already exited: docker ps -a root@docker:/home/root# docker ps -a CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 605e3928cddd centos:latest "/bin/bash" 31 minutes ago Exited (0) 31 minutes ago kickass_swartz Anything I did wrong? How can I troubleshoot this issue? "docker run hello...

Docker socket crash after stack up

Image
Docker socket crash after stack up I trying to deploy docker stack, that includes my development environment. But in random cases I have next error: failed to create service < service_name >: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? Next I restart docker daemon. Sometimes it requires to kill docker processes and shims. I deleting old stack and build again. Some times docker successfully finishes build, but socket crashes on the starting stage. Also all containers work properly when I starting it in regular mode, without swarm or stack. It is not work exactly inside swarm. I have used next command to build: $ docker stack deploy dev-env-stc -c docker-compose.yml Environment run in Antergos Linux(Arch). Layout is like at the diagram Nginx container and docker networks created using commands: $ docker run --detach --name nginx-main --net dev-env-ext --ip 10.20.20.10 --publish 80:80 --publish 443:443 --volume /env-vol/nginx...

How to download all dependencies with vgo and a given go.mod?

How to download all dependencies with vgo and a given go.mod? I'm working on a go project, using vgo, with a Dockerfile, and I'd like docker to cache the dependencies of the project such that it has two properties: go.mod go.mod Right now, I do: ... RUN go get -u golang.org/x/vgo COPY . /go/src/whatever RUN vgo install ... But if you change a go file, the dockerfile will have to be rebuilt from the COPY layer onwards. COPY What I'd like, in short, is to do: ... RUN go get -u golang.org/x/vgo COPY go.mod /go/src/whatever RUN vgo install_dependencies COPY . /go/src/whatever RUN vgo install ... That way, if I change go.mod , all the dependencies will be downloaded and rebuilt, but otherwise, we can proceed right to building the binary. go.mod I can see a couple of ways to get behavior like this, but all of them have drawbacks: $GOPATH/src/mod vgo mod -vendor vgo mod -vendor go.mod vgo mod -vendor Can you think of a way for me to get behavior like my imaginary vgo install_depe...

Does Azure Service Fabric do the same thing as Docker?

Does Azure Service Fabric do the same thing as Docker? My thinking is that people use Docker to be sure that local environment is the same as production and that I they can stop thinking about where are their apps running physically and balancing mechanisms should just allocate apps in best places for that moment. I'm 100% web based and I'm going to move to cloud together with our databases, and what cannot be moved will be seamlessly bridged so the corporate stuff and the cloud will become one subnetwork. And so I'm wondering, maybe Service Fabric already does the same thing that Docker does plus it gives as address translation service (fabric:// that acts a bit like DNS for the processes in fabric space) plus (important for some) encourages on demand worker allocation - huge scalability perk. 2 Answers 2 It's confusing since Docker (the company) is trying to stake claims in everyth...