Commit 5139420a authored by Ondřej Surý's avatar Ondřej Surý

Install nodejs LTS (12.x) with npm from nodesource

parent 3451e3ba
......@@ -32,6 +32,7 @@ abi_check_debian_buster_amd64 := yes
coccinelle_debian_buster_amd64 := yes
compiledb_debian_buster_amd64 := yes
cppcheck_debian_buster_amd64 := yes
nodejs_debian_buster_amd64 := 12
danger_debian_buster_amd64 := yes
dnstap_alpine_3.11_amd64 := yes
dnstap_debian_buster_amd64 := yes
......@@ -87,6 +88,7 @@ $(TARGETS): COMPILEDB = $(compiledb_$(VENDOR)_$(VERSION)_$(ARCH))
$(TARGETS): CPPCHECK = $(cppcheck_$(VENDOR)_$(VERSION)_$(ARCH))
$(TARGETS): DANGER = $(danger_$(VENDOR)_$(VERSION)_$(ARCH))
$(TARGETS): DNSTAP = $(dnstap_$(VENDOR)_$(VERSION)_$(ARCH))
$(TARGETS): NODEJS = $(nodejs_$(VENDOR)_$(VERSION)_$(ARCH))
$(TARGETS): PYTHON_QA = $(python_qa_$(VENDOR)_$(VERSION)_$(ARCH))
$(TARGETS): RESPDIFF = $(respdiff_$(VENDOR)_$(VERSION)_$(ARCH))
$(TARGETS): SHELLCHECK = $(shellcheck_$(VENDOR)_$(VERSION)_$(ARCH))
......@@ -106,6 +108,7 @@ $(TARGETS):
-e 's,@DANGER@,$(DANGER),g' \
-e 's,@DNSTAP@,$(DNSTAP),g' \
-e 's,@KYUA_GIT_COMMIT@,$(KYUA_GIT_COMMIT),g' \
-e 's,@NODEJS@,$(NODEJS),g' \
-e 's,@PYTHON_QA@,$(PYTHON_QA),g' \
-e 's,@RESPDIFF@,$(RESPDIFF),g' \
-e 's,@SHELLCHECK@,$(SHELLCHECK),g' \
......
......@@ -104,8 +104,10 @@ RUN if [ "@CLANG@" -ge "9" ] 2>/dev/null; then \
RUN if [ "@COCCINELLE@" = "yes" ]; then apt-get -y install coccinelle; fi
RUN if [ "@COMPILEDB@" = "yes" ]; then pip3 install compiledb; fi
RUN if [ "@CPPCHECK@" = "yes" ]; then apt-get -y install cppcheck; fi
RUN if [ -n "@NODEJS@" ]; then curl -sL https://deb.nodesource.com/setup_@NODEJS@.x | bash - && apt-get install -y nodejs; fi
# https://github.com/danger/python/pull/8
RUN if [ "@DANGER@" = "yes" ]; then apt-get -y install npm && npm install -g danger@9 && pip3 install danger-python && sed -i 's|OPEN = "open"|OPEN = "opened"|' /usr/local/lib/python3.7/dist-packages/danger_python/models.py; fi
RUN if [ -n "@NODEJS@" ] && [ "@DANGER@" = "yes" ]; then npm install -g danger@9 || cat /root/.npm/_logs/*.log; fi
RUN if [ -n "@NODEJS@" ] && [ "@DANGER@" = "yes" ]; then pip3 install danger-python && sed -i 's|OPEN = "open"|OPEN = "opened"|' /usr/local/lib/python3.7/dist-packages/danger_python/models.py; fi
RUN if [ "@DNSTAP@" = "yes" ]; then apt-get -y install libfstrm-dev libprotobuf-c-dev protobuf-c-compiler; fi
RUN if [ "@PYTHON_QA@" = "yes" ]; then pip3 install flake8==3.8.1 pylint==2.5.2; fi
RUN if [ "@RESPDIFF@" = "yes" ]; then apt-get -y install python3-dpkt python3-lmdb python3-numpy python3-scipy python3-tabulate; fi
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment