Sorry if the title is a little vague but I need to find the real culprit.
I have this setup:
-a git repository called MyRepo.
-a Jenkins instance that auto-builds MyRepo. On post-build steps there’s a simple script that executes:
#!/bin/bash branch=$1 docker build -t server.com:5000/MyRepo:$branch . docker push server.com:5000/MyRepo:$branch
-The server.com:5000 is the Nexus instance. Here all docker images are saved and can be pulled by docker-compose installations.
FROM node:8-slim WORKDIR /usr/src/webapp COPY package.json ./ COPY start_http_server.sh ./ COPY site ./site COPY resources ./resources COPY node_modules ./node_modules EXPOSE 8000 CMD ["./start_http_server.sh"]
What I’m seeing is that the final docker image I pull from Nexus doesn’t have some files, eg. this is the original structure of resources folder:
/resources/awesome/js /resources/awesome/css /rseources/awesome/bower.json /resources/awesome/scss
and the docker image is totally missing the js folder.
So, to debug I added in Dockerfile "RUN ls -la resources/awesome/" before and after the "CMD ["./start_http_server.sh"]" line.
I then watch Jenkins build logs and the output of the command is correct, all folders are there.
So is the issue Nexus side? Is there any cache or something similiar that Nexus uses and avoids updating contents?
Source: Docker Questions