How to run cronjob in docker, and how to see the result?

currently, I try to run a cronjob in my container Docker, but I see no result. My Dockerfile look like that: # Pull base image. FROM ubuntu # Upgrade system RUN apt-get update && apt-get dist-upgrade -y –no-install-recommends # INSTALL GIT RUN apt-get install -y git-core # INSTALL mysql-client RUN apt-get install -y mysql-client #INSTALL […]

connecting to exposed docker container

I’m trying to expose a docker container to the outside world, not just the host machine. When I created the image from a base CentOS image it looks like this: # install openssh server and ssh client RUN yum install -y openssh-server RUN yum install -y openssh-clients RUN echo ‘root:password’ | chpasswd RUN sed -ri […]

Tomcat doesn't start in docker container because it can't create log files

I’m trying to run Tomcat in docker container on behalf of tomcat user. Here’s the Dockerfile: FROM centos:latest … RUN groupadd -g743 tomcat RUN useradd -u734 -M -s /bin/nologin -g tomcat -d /opt/tomcat tomcat … RUN chown -R tomcat:tomcat /opt/tomcat/ RUN chmod o+rwx /opt/tomcat … USER tomcat CMD [“/opt/tomcat/bin/catalina.sh”, “run”] I run the container in […]

Build of docker image with centos:6.6 fails when trying to update repo

I have the following simple Dockerfile: FROM centos:6.6 USER root RUN yum clean all RUN yum update And I am trying to build it as usual: docker build -t myimage/hadoop . But I have the following error and I can’t find the solution: Error: Cannot find a valid baseurl for repo: base Could not retrieve […]

Why docker 1.11.0 use too much disk space on /run/docker/libcontainer?

I configured a separated storage for docker. It works fine before upgrading docker to version 1.11.0. I did it via specifying the storage path in /etc/default/docker file. DOCKER_OPTS=”–dns 8.8.4.4 -g /volume/docker” However I observed the docker also occupied lots of disk space(more than 7G) on /run/docker/libcontainer/ which makes the disk of ‘/’ 100% used after […]

data only container for elasticsearch

Im having problems getting data only container working with elasticsearch. I can get it to work where volume is a host volume but not for data only container. Here is my data only container: # Dockerfile FROM busybox VOLUME /src/elasticsearch/data VOLUME /src/elasticsearch/log VOLUME /src/elasticsearch/plugins VOLUME /src/elasticsearch/config ADD ./elasticsearch.yml /src/elasticsearch/config/elasticsearch.yml CMD /bin/sh Build and run it: […]

Deis not creating a build when pushing application

I am trying to push up a Node app using Deis (which has worked for months for me with this application but just recently stopped working) on AWS. I notice now that when I push up my application, a new release is not created; however, if I change a environment variable using deis config:set then […]

Selenium in Docker container, Can we take screen shot

I’m trying to execute selenium tests in Docker container (Linux Centos OS). I’ve created three docker containers, one as hub & other two as node. I’m trying to capture screen shot at a step. Didn’t get any exception. But I’m not able to find the screen shot (jpg file) on container. I want to know […]

How to publish Docker on AWS from sbt-native-packager?

I’m using sbt-native-packager to build Dockers for my Scala project. I’d like to deploy on a repository running in my AWS account. How can I set up sbt-native-packager to do this? On AWS I installed docker on an instance then installed and ran the samalba registry with defaults like this: docker run -d -p 5000:5000 […]

(spotify) Maven docker builder for Java

I’m trying to build docker image for Java using (spotify) Docker Maven Plugin. But while running mvn package docker:build on my project, I’m constantly getting the following error: Failed to execute goal com.spotify:docker-maven-plugin:0.2.6:build (default-cli) on project gs-spring-boot-docker: Exception caught: Get https://index.docker.io/v1/repositories/library/java/images: dial tcp: lookup index.docker.io on 10.1.2.2:53: no answer from server -> [Help 1]

Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.