Closed jibbajabber closed 3 years ago
I tested this morning on MacOS and Centos and I'm unable to reproduce your issue - my containers come up fine. The only steps required for Centos (fresh VM, 8.2.2004 - I didn't match your version here) were installing docker-engine (20.10.5), docker-compose (1.29.0), git clone https://github.com/Netflix/lemur-docker.git
, and make
.
Is there any chance you could try this on a different host machine to see whether you get a different result? I don't have an explanation at the moment but searching for ESOCKETTIMEDOUT
makes me wonder if the host machine might have a slow network or some other network configuration that could be causing problems.
Regarding some of your other observations:
I noticed when running make that npm is expected but not listed as a requirement, my local npm installed is 3.10.10
npm
is installed here in the Dockerfile
I also noticed running docker-compose up as is...
You're correct, the directory got changed at some point and the README is wrong, I'll fix that - thanks for pointing it out.
Also the docker-compose version...
Not sure why this is showing up for you; I'm not seeing that when using the exact same docker version as you noted. Docker's versioning table seems to suggest 3.7 should work: https://docs.docker.com/compose/compose-file/compose-versioning/
In addition to the bower url failures (as per the pastebin URL) I see the following deprecated warnings:
I see these as well, but they shouldn't be a blocking issue. This is something that would need to be taken up in the main lemur
repo, and I'm not sure if anything is blocking us on that.
I did notice that from inside the container during the build process if I try to curl a bower failed url I get a redirection, could this be the cause?:
I don't think so - I see the same in my (successful) container.
One other item to note, failed builds don't clean up what look like ephemeral containers
Thanks, good feedback; I can try to look into that.
I'm not hugely familiar with npm but I'm attempting to build lemur again with the following additions (I'm not behind a proxy):
npm config delete proxy && \
npm config delete http-proxy && \
npm config delete https-proxy && \
npm config set proxy null && \
npm set maxsockets 3 && \ :
So this is now:
RUN apt-get update && \
apt-get -y --no-install-recommends upgrade && \
apt-get install -y --no-install-recommends libpq-dev curl build-essential locales libffi-dev libsasl2-dev libldap2-dev \
dh-autoreconf git python3-dev python3-pip python3-venv python3-wheel nodejs npm && \
locale-gen en_US.UTF-8 && export LC_ALL=en_US.UTF-8 && \
npm config set registry http://registry.npmjs.org/ && \
npm install npm -g && \
echo "Running with nodejs:" && node -v && \
python3 -m venv /opt/venv && \
echo "Running with python:" && /opt/venv/bin/python3 -c 'import platform; print(platform.python_version())' && \
/opt/venv/bin/python3 -m pip install --no-cache-dir --upgrade pip setuptools wheel && \
/opt/venv/bin/python3 -m pip install --no-cache-dir -e . && \
npm config delete proxy && \
npm config delete http-proxy && \
npm config delete https-proxy && \
npm config set proxy null && \
npm set maxsockets 3 && \
npm install --unsafe-perm && \
node_modules/.bin/gulp --cwd /opt/lemur build && \
node_modules/.bin/gulp --cwd /opt/lemur package && \
npm cache clean --force && \
rm -rf node_modules && \
python3 -c 'print(" \033[32m BUILDER DONE \033[0m ")'
If my suggestions around https, clone path and npm are valid and helpful I can raise a PR
Interesting, I wonder why that would be necessary. If you've got time @jibbajabber, would you be able to try getting all those config values before deleting them? I'm curious to know if your container has a value set for some reason, and if there's anything we can change earlier to avoid needing this.
npm config get proxy && \
npm config get http-proxy && \
npm config get https-proxy && \
npm get maxsockets && \ :
At any rate, if it fixes your problem, we should probably add it. I'll find some time in an hour or two to verify it doesn't break anything for me, but if not I think a PR would be helpful (I already fixed the clone path though, thanks for pointing it out!).
Thanks for the fast response š
No change so far sadly, still get time outs. I tried adding to package.json pretest
and prelint
and rebuilding to see if it resolved this issue (I'm quite clueless when it comes to npm so fumbling my way around) but no change, for clarity I added:
"scripts": {
"postinstall": "node_modules/.bin/bower install --allow-root --config.interactive=false",
"pretest": "npm config rm proxy && npm config rm https-proxy && npm config delete http-proxy && npm config delete https-proxy && npm install && npm run build_static",
"build_static": "gulp build",
"prelint": "npm config rm proxy && npm config rm https-proxy && npm config delete http-proxy && npm config delete https-proxy && npm install",
"lint": "jshint lemur/static/app/",
"test": "gulp test"
},
Happy to try whatever helps the project could you elaborate on "getting all those config values", sorry not too sure what you'd like me to collect but happy to do so
The values added so far (but hasn't fixed my issue):
npm config rm proxy
npm config rm http-proxy
npm config rm https-proxy
npm config delete proxy
npm config delete http-proxy
npm config delete https-proxy
npm config set proxy null
npm set maxsockets 3
Will check in later on tonight to see if there is anything else I can do, if useful
RE npm
local requirement, you're right; I just removed npm
from my system and ran make
again without an issue relating to dependencies, hmm sorry about that, not sure what happened there and I don't have the log, must have been user error on my part.
I'll spin up another CentOS 7 and 8 VM where I am currently and on a different site to confirm and report back either later tonight or some time tomorrow šš¼
Working without issue on a new centos 7 environment (no npm changes required), so I won't test on centos 8, could well be something really off in my other environment.
Apologies for distraction and thank you for taking a look at this š
Hi, I'm seeing issues when trying to evaluate lemur for the first when following the projects README https://pastebin.com/9wBZv8Zp
os:
CentOS 7.6.1810
docker-ce:20.10.5
docker-compose:1.29.0
command ran:make
result: During the make process bower is raising ESOCKETTIMEDOUT consistently so the containers are never created expected: All containers required created and lemur hosted on localhost:87 and localhost:447I noticed when running
make
that npm is expected but not listed as a requirement, my local npm installed is3.10.10
I also noticed running
docker-compose up
as is, also fails if make isn't run first as the expected directory structure for lemur is off as per the README, I think it needs to begit clone --depth=1 git@github.com:Netflix/lemur.git lemur-build-docker/lemur
instead however perhaps it makes sense to use https urls throughout instead to satisfy all users sogit clone --depth=1 https://github.com/Netflix/lemur lemur-build-docker/lemur
maybe?Also the docker-compose version is set to
3.7
(currently) but for me I have to change this to3.3
else:I'm hoping this is all user error and I'm doing something wrong, but can't currently see why bower is failing to resolve what can be resolved on the host that runs docker.
In addition to the bower url failures (as per the pastebin URL) I see the following deprectaed warnings:
I did notice that from inside the container during the build process if I try to curl a bower failed url I get a redirection, could this be the cause?:
One other item to note, failed builds don't clean up what look like ephemeral containers, it's no big deal but would be nice if those were removed if a make/docker-compose fails