Questions tagged [dockerfile]

1

votes
1

answer
94

Views

Docker - Import Json Docment Inside The Solr Core

I want to ask if there is a way to import Json document into the core from the docker file while creating the core, or if I can mount a pre-created core directory with the Json file already imported inside it. An another method than import the document from Solr server page in Documents core tab and...
Ebraheem Alrabee'
1

votes
0

answer
191

Views

Docker Compose file to Docker Stack

I have found an awesome repo that uses docker-compose however I would like to use it Docker Cloud Stacks (I am a newbie). What would I have to do to be able to swap it over? docker-compose: version: '2' services: mariadb: image: wodby/mariadb:10.2-3.0.2 php: # 1. Images with vanilla WordPress – wo...
Jess McKenzie
1

votes
1

answer
432

Views

Shared build logic with docker-compose and multi-stage Dockerfiles

I am using docker-compose with multi-stage Dockerfiles to build and run multiple services. This works, but the 'build' portion of each multi-stage build is largely copy-and-pasted between each service's Dockerfile. I want to reduce the copy-and-paste / centralize the common build logic in one spot....
LegNeato
1

votes
2

answer
877

Views

How to add known_hosts for passwordless ssh within docker container in docker-compse.yml?

I want to have passwordless ssh within two docker containers. How to add known_hosts entry for that using docker-compose.yml file I want to implement ansible on docker env. To deploy and run rpm on deployment node, I need passwordless ssh from container1 to container2. For that I have to add known_h...
user2664210
1

votes
0

answer
19

Views

There are two dockerfiles that I'm pulling, how do I stop the second docker file without affecting the other one?

I'm really sorry but I am completely new to docker.. so I had an error network and I tried pulling again because I thought the first one stop. And this happened.. How do you stop the second docker file without affecting the first one??
Alianne
1

votes
0

answer
416

Views

How to specify build options for docker-compose build stage?

I have a main docker-compose.yml: version: '3' services: recognizer: container_name: recognizer build: ./recognizer hostname: recognizer restart: always ports: - 8084:8084 network_mode: 'host' I have a folder recognizer with Dockerfile and docker-compose.yml: Dockerfile: FROM openjdk:8 RUN mkd...
Denis
1

votes
2

answer
81

Views

command option gets ignored in docker-compose.yaml

These are the contents of my docker-compose.yaml. rabbitmq: image: docker_rabbitmq hostname: rabbitmq restart: always ports: - '5672:5672' elasticsearch: image: docker_elasticsearch hostname: elasticsearch restart: always ui-console: image: docker-ui-console hostname: ui-console restart: always port...
user2010672
1

votes
0

answer
435

Views

Selenium WebDriver - Process unexpectedly closed

I have built a Docker image on top of Node to execute a bunch of Selenium tests. Here is my Dockerfile: #Dockerfile for individual node instance FROM node:latest #add the .js Selenium testcase files COPY ./tests /tests #add geckodriver (latest version) from local directory COPY geckodriver-v0.1...
wallnfl
1

votes
0

answer
465

Views

Get Environment variable from .env file and pass to Dockerfile

This seems like a huge oversight on the developers behalf as I can't understand the use case where you don't want the image build to know about .env variables. I'm running Laravel and I'm access some AWS keys from with a .env file. When I try to build an image via a Dockerfile, the php compsoer auto...
MattBoothDev
1

votes
0

answer
682

Views

ERROR: unsatisfiable constraints: while installing package in alpine

I am trying to build a docker image based on Alpine and I need to install few packages in it. Here is exactly what I am trying to do: FROM alpine:latest RUN apk --no-cache add ca-certificates=20161130-r2 openssl=1.0.2k-r0 But when I run docker build, here is the error I get: RUN apk --no-cache add c...
Pensu
12

votes
5

answer
6k

Views

Is there a way to lint the Dockerfile?

If a Dockerfile is written with mistakes for example: CMD ['service', '--config', '/etc/service.conf] (missing quote) Is there a way to lint it to detect such mistake before building?
eloone
1

votes
0

answer
229

Views

Docker not running flask app after successful creation and running

I am not able to make Docker work on my Flask app My flask app is successfully running locally with no errors I m not getting any errors while building and running docker container based on my dockerfile Docker successfully builds the entire image Flask successfully runs locally No errors are gettin...
smk
1

votes
0

answer
92

Views

How can I write this as CMD [ … ] syntax?

It's good practice to start the service with CMD ['/go/bin/myapp'] instead of CMD /go/bin/myapp In the first way, SIGTERMs are caught by the applicaiton, while in the second way, they are caught by the underlying /bin/sh script, which does not forward them to the service. I learned this from https:/...
John Somen
1

votes
0

answer
182

Views

Docker distributed cache

I'm looking for a solution to share docker cache across multiple CI instances The main use case is when building a new image using instance A, then building the same image using instance B from scratch, instead of having shard docker cache This causes longer build / push time, and it can be shortene...
gCoh
1

votes
0

answer
79

Views

How can I make PyCharm recognize Dockerfiles that are not called exactly Dockerfile?

In my project, there are several Dockerfiles. As they are in the same folder they can't all be named Dockerfile. PyCharm only styles the one named Dockerfile as Dockerfile. Dockerfile_1, for example, gets no styling and no inspections.
Anna Ira Hurnaus
1

votes
1

answer
738

Views

Docker: libpython2.7.so.1.0: cannot open shared object file: No such file or directory

Dockerfile FROM python:2.7 as python CMD ['bash'] FROM ubuntu COPY --from=python /usr/local /usr/local Then, docker build -t ubuntuapp . docker run ubuntuapp /usr/local/bin/python Output: local/bin/python: error while loading shared libraries: libpython2.7.so.1.0: cannot open shared object file: No...
ealeon
1

votes
1

answer
779

Views

Dockerfile for a gitlab container

I am doing a school project where I must install gitlab ce in a debian Docker container. I came up with something but the gitlab installer gets stuck on : ruby_block[supervise_redis_sleep] action run I read somewhere you can Ctrl+C and reconfigure to skip this error but as it is a school project I c...
Emmanuel Ruaud
1

votes
1

answer
1.5k

Views

psql: could not translate host name “postgres” to address: Temporary failure in name resolution

i cloned from github a docker-mail repository 'https://github.com/1it/docker-mail' and ran the docker-compose.yml. It created 6 containers and 6 images. Then i have created a Dockerfile with a basis Image from one of these 6 Images 'dockermail_roundcube', to have only one Image which contains all se...
guguli
1

votes
0

answer
22

Views

Re-route backend routes between containers within the same host

Hi I'm new to docker containers. I have the following setup: The docker host is running on a Linux server, it is running 4 apps: reverse-proxy (nodejs-based) frontend container backend container active mq container All of them are running in my-network Here is the problem, I would like to re-route e...
Mathers
1

votes
0

answer
373

Views

Docker push fails after multiple retries on a specific layer

I'm trying to push my own docker image for an angular 5 project that I've built. My docker image extends the well known node:carbon image and runs the following commands: FROM node:carbon WORKDIR /usr/src/app COPY package.json . COPY package-lock.json . RUN npm install --no-optional COPY . . EXPOSE...
Tudor Ravoiu
1

votes
1

answer
2.4k

Views

Getting containers to run with a Jenkinsfile

I am having trouble with writing making Jenkinsfile. My environment: A server running docker Jenkins is running as a container on the server I have a Docker image on DockerHub, and I have no problem fetching that image. My Jenkinsfile currently looks like this: pipeline { agent { docker { imag...
emilrn
1

votes
0

answer
26

Views

Can dockerfile comments be in foreign languages?

I am translating documentation for non-English users learning Docker. We have some example Dockerfiles with comments which we would like to translate for better understanding by the students. Are non-English languages, specifically Japanese, allowed in Dockerfile comments? If the students copy/paste...
Sara Hammer
1

votes
0

answer
581

Views

Running the basic .NET Core MVC App on SSL, HTTPS inside Docker Container

I am learning how to run my .net core web applications on docker (on windows host) with SSL. I started with the basic application that .net core gives by doing 'dotnet new mvc'. Then I moved ahead and modified the code inside Program.cs to listen only on port 443. public static IWebHost BuildWebHos...
thinkmmk
1

votes
1

answer
18

Views

How to make dockerfile and .conf file are not accessible direct through url

How to make dockerfile and .conf file are not accessible direct through url Look this url http://localhost/dockerfile http://localhost/nginx.conf If I Open this url this files are downloadable which should be not. How can i prevent this?
ImBS
1

votes
0

answer
108

Views

dotnet core 2.0 commands not running in docker

I'm trying to set up my dotnet core app to run through docker on my mac. My Dockerfile looks like this: FROM microsoft/dotnet:sdk AS build-env WORKDIR /app # copy csproj and restore as distinct layers COPY *.csproj ./ RUN dotnet restore # copy everything else and build COPY . ./ RUN dotnet publish...
Paul W
1

votes
0

answer
36

Views

Containers are not accessible to each other

I have had the problem since the beginning that I can not connect between two containers. I have read and adjusted all available tutorials, but as it is presented in all these tutorials, it does not work for me. I get from my app always the message that the connection was thrown back, no matter what...
p.0
1

votes
2

answer
479

Views

Linked-Data-Theater | standard_init_linux.go:195: exec user process caused “no such file or directory”

While running the docker-compose up for git project Linked-Data-Theater I am getting error standard_init_linux.go:195: exec user process caused 'no such file or directory Below is a stack trace, [email protected] MINGW64 /d/test/Docker/LinkData_Theater_Repo/Linked-Data-Theatre (master) $ dock...
1

votes
0

answer
323

Views

Copying MSI to Container on Docker for Windows

I've got a basic ASP.NET core app on Windows Server 2016. The app runs successfully with Docker when built but but I am trying to modify the dockerFile to copy an MSI from my local dev workstation to the container when it's built however; I keep getting a multitude of errors. Essentially I have an a...
Kevin
1

votes
0

answer
582

Views

docker build can not access host network

I want to build a docker image by Dockerfile, the docker version is 1.12.6. docker version Client: Version: 1.12.6 API version: 1.24 Package version: docker-1.12.6-71.git3e8e77d.el7.centos.1.x86_64 Go version: go1.8.3 Git commit: 3e8e77d/1.12.6 Built: Tue Jan 30 09:17...
axiaoxin
1

votes
2

answer
740

Views

Copy nginx.conf file into the container when container is launched

I have nginx.conf file on our artifactory (http://artifactory.abc.com). I want to dowload and replace the file (/etc/nginx/nginx.conf) inside the container when the container is launched so that I do not have to rebuild the Dockerfile each time I make a change to my nginx.conf file. I can just uploa...
codechef
1

votes
2

answer
482

Views

Docker Container not running for spring boot application

I am new to docker. I am trying to run my application using docker. However, it throws an error for me when I try to run exec -it /bin/bash command on the container error: Error response from daemon: Container is not running Following is my docker file (Dockerfile): FROM openjdk:8-jdk-alpine EXPOSE...
1

votes
0

answer
56

Views

Docker: make command only fails during auto build

the build of the following docker image fails during the command: RUN cd /eman2_build && make -j Image and log output: https://hub.docker.com/r/thorstenwagner/docker-yolo-keras/builds/bj9wvm9zc6zgghrkphance8/ However, when I comment out the last two commands the build is successfull. If I then run t...
Thorsten Wagner
1

votes
1

answer
75

Views

Mount host dir into docker container without volume?

Is mounting (--mount or -v) a host directory or host volume into a container only possible if the image defines a volume? I tried to do docker run -d -v maven-m2-repo:/root/.m2 maven:3-jdk-8-alpine SOME-MAVEN-PROJECT-RUN as described in https://github.com/carlossg/docker-maven in order to preserve...
Sebi
1

votes
2

answer
895

Views

Docker Swarm Deploy a local Dockerfile

I am trying to deploy a stack of services in a swarm on a local machine for testing purpose and i want to build the docker image whenever i run or deploy a stack from the manager node. Is it possible what I am trying to achieve..
DevScript
1

votes
0

answer
138

Views

Create Docker image for deb packages

I have a deb packages created, I need to set up one docker image for these files. .buildinfo .changes .deb .ddeb Any pointers or documentation to create a Docker image. I have searched for same in google and found only how to create deb packages using docker containers.
Bobby
1

votes
0

answer
256

Views

Grails app runs locally but won't run within Docker container

I've got an app built in Grails 3.3 that I'm trying to get running within a Docker container. I'm building the app with a simple grails package command which creates a WAR file in the build/libs directory of the project. I am not using any of the options to build a self-contained, executable JAR fil...
soapergem
1

votes
1

answer
212

Views

Setting up multi-stage Docker build on Heroku

[Edit: It looks like my specific question is how to push a multi-stage Docker build to Heroku] I'm trying to set up a NLP server using the spacy-api-docker Github repository. The project README lists a base image (jgontrum/spacyapi:base_v2) with no included language models as well an English languag...
1

votes
1

answer
393

Views

How can I mount a second disk to a Docker container?

I have a Docker container on Ubuntu. This container uses a PCIe drive and I want to add a SATA drive. Neither drive should share data with other containers. How can I do this? From the command docker run? Or through the Dockerfile? Here's the lsblk on the server: # lsblk NAME MAJ:MIN RM S...
Justin Cloud
1

votes
0

answer
373

Views

Add predefined Jenkins jobs to Jenkins master in docker

I have now searched the Internet for 2 whole days without any progress. There might be so, that the answer is just a click away, but I cannot find it. I'm blinded. I work on Windows 10 by the way... The problem is that I want to create a simple Dockerfile, that can create a Docker image with a Jenki...
aoki
1

votes
2

answer
1.2k

Views

Kubernetes with Docker unable to change from default port of 80

I am running a dotnet core app using Kubernetes with Docker. The setup is as follows: APP In the dotnet core app, I have Kestrel server listening on port 8080 by setting the following in Program.cs: public static IWebHost BuildWebHost(string[] args) => WebHost.CreateDefaultBuilder(args) .UseStartup(...
JMad

View additional questions