Creating image in Docker fails - image

I'm trying to create my own image on Docker container. I wrote my Docker file as given below:
FROM ubuntu:latest
RUN apt-get update && apt-get install astyle ruby
But on running
docker build -t username/newname .
It gives an error Error response from daemon:
mkdir /var/lib/docker/tmp/docker-builder705720973: no space left on device
I'm new to Docker. Any help would be appreciated. Thanks in advance

You must have pulled a lot of images i guess. Check all your images using following command:
sudo docker images
If you see many images, try deleting some that you don't need anymore using the following command
sudo docker rmi <iamge_id>
Hope that helps

Related

Docker setup on WSL for a Laravel website

I have entered into the WSL terminal the following command:
docker compose build --no-cache && docker compose up
This is what happened:
I have not downloaded anything outside of Docker on this computer and I have cloned this "backend" from the repository.
I have no experience in Docker or Laravel.
What methods should I start with to fix this?
The option -g in the groupadd command needs to be numerical, you can't use use the word sail.
See Ubuntu's documentation about that command and option here.

How to add a docker image in the Dockerfile for making a docker container

I am fairly new to docker containers and images. I am trying to make a Dockerfile with ubuntu 18.04 and another docker image from http://www.ensembl.org/info/docs/tools/vep/script/vep_download.html#docker tool.
Later, I want to generate a docker container for the above-linked tool as a base image and ubuntu as the parent image makefile. For example, here is how you will do it via command line for the installation of the image for the tool within ubuntu os.
docker pull ensemblorg/ensembl-vep
docker run -t -i ensemblorg/ensembl-vep ./vep
When I try to install the Ubuntu:18.04 and the above docker image via make file it says
docker build -t "KM:vep-96.0" .
Sending build context to Docker daemon 4.608kB
Step 1/4 : FROM ubuntu:18.04
18.04: Pulling from library/ubuntu
5bed26d33875: Pull complete
f11b29a9c730: Pull complete
930bda195c84: Pull complete
78bf9a5ad49e: Pull complete
Digest: sha256:bec5a2727be7fff3d308193cfde3491f8fba1a2ba392b7546b43a051853a341d
Status: Downloaded newer image for ubuntu:18.04
---> 4e5021d210f6
Step 2/4 : MAINTAINER ARJ
---> Running in 8f1f7e837703
Removing intermediate container 8f1f7e837703
---> 511205d197d6
Step 3/4 : RUN pull ensemblorg/ensembl-vep
---> Running in b584b3b1738c
/bin/sh: 1: pull: not found
The command '/bin/sh -c pull ensemblorg/ensembl-vep' returned a non-zero code: 127
Makefile:5: recipe for target 'docker-build' failed
make: *** [docker-build] Error 127
Here is how my Dockerfile looks like,
# NGS580 container for making reports with R 3.4.3
FROM ubuntu:18.04
MAINTAINER ARJ
# ~~~~~ VEP ~~~~~ #
FROM pull ensemblorg/ensembl-vep
run -t -i ensemblorg/ensembl-vep ./vep
I would like to know whether or not it is possible to have another docker image within a Dockerfile? If not how can I have the tool without needing to install a lot of modules? Any suggestions or help would be much appreciated.
Thank You!

ImageMagick or GraphicsMagick can not be found

I have got Rocket.Chat up and running on Plesk Onyx (ubuntu 16.04.3) using the docker system by running these commands.
docker run --name db -d mongo:3.0 --smallfiles
docker run --name rocketchat --link db -d rocket.chat
Everything is working accept the Avatar Resize which is giving and error:
'The image resize will not work because we can not detect ImageMagick or GraphicsMagick installed on your server.'
I have both installed on the server but for some reason it's not being detected by Rocket.Chat.
Am I missing something?
The other issue I get is when I go into the docker settings I have to change Accounts_AvatarStorePath to ACCOUNTS_AVATARSOREPATH and remove Accounts_AvatarStorePath otherwize I get an error about lowercase letters.
Figured it out finally.
There seems to be an issue with that image, so switched to the other offical image and now all working.

Error while running a container using docker

I have installed docker in my machine
I could successfully pull images from the repository and the pulled images are clearly listed when I see the list of images pulled.
The docker service was also started using
sudo service docker start
However, when I try to run the same using the command,
sudo docker run -it ubuntu:12.04
I am getting the following error
docker: Error response from daemon: Container command '/bin/bash' not
found or does not exist..
The issue remains the same for any image that I have tried with
What could be the reason for this issue?
It depends on your version of docker, but check if you have issue 23411, where adding a workdir is needed:
sudo docker run --workdir /var -it ubuntu:12.04
There seem to be some recent bug in start.go, and a PR in progress.

Installing elasticsearch docker image fails on command not found

I'm trying to install elasticsearch from an image I've created on another machine, however when I create the container it say that the command not found. I've understood that the command is not exported as part of the image, however I can't find the right command to spesify for it to work.
on Machine A I'm creating the image as such:
sudo docker pull elasticsearch
sudo docker save -o "elastic.image.tar" elasticsearch
On machine B I'm importing the image and trying to run it
sudo docker import "elastic.image.tar"
sudo docker run -d elasticsearch
on the docker run I get
docker: Error response from daemon: No command specified.
See 'docker run --help'.
I've also tried the following commands:
sudo docker run -d elasticsearch elasticsearch
sudo docker run -d elasticsearch "/docker-entrypoint.sh elasticsearch"
sudo docker run -d elasticsearch "/usr/share/elasticsearch/docker-entrypoint.sh elasticsearch"
sudo docker run -d elasticsearch "/bin/bash"
None of them worked, all returned responce like:
docker: Error response from daemon: Container command 'XXX' not found or does not exist..
What is the right command to specify here?
Can you try docker load -i elastic.image.tar and call docker run elasticsearch. Check this question to know some differences between save/load and export/import.

Resources