Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refine SED_DPKG: install dependencies from apt source #126

Closed
wants to merge 3 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Detect unexpected REMOVED from apt-get install
qiluo-msft committed Dec 16, 2016
commit 0a0e69cf49038a6aa7341838f41395996e81f27f
2 changes: 1 addition & 1 deletion slave.mk
Original file line number Diff line number Diff line change
@@ -255,7 +255,7 @@ $(addprefix $(TARGET_PATH)/, $(SONIC_DOCKER_IMAGES)) : $(TARGET_PATH)/%.gz : .pl
mkdir -p $($*.gz_PATH)/python-wheels $(LOG)
sudo mount --bind $(DEBS_PATH) $($*.gz_PATH)/deps $(LOG)
sudo mount --bind $(PYTHON_WHEELS_PATH) $($*.gz_PATH)/python-wheels $(LOG)
sed 's/SED_DPKG/RUN cd deps \&\& dpkg -i $(shell printf "$(subst $(SPACE),\n,$(call expand,$($*.gz_DEPENDS),RDEPENDS))\n" | awk '!a[$$0]++') || apt-get -y install -f/g' $($*.gz_PATH)/Dockerfile.template > $($*.gz_PATH)/Dockerfile
sed 's/SED_DPKG/RUN cd deps \&\& dpkg -i $(shell printf "$(subst $(SPACE),\n,$(call expand,$($*.gz_DEPENDS),RDEPENDS))\n" | awk '!a[$$0]++') || { o=$$(apt-get -y install -f | tee \/dev\/tty); !(echo $$o | grep "The following packages will be REMOVED:"); }/g' $($*.gz_PATH)/Dockerfile.template > $($*.gz_PATH)/Dockerfile
docker build --no-cache -t $* $($*.gz_PATH) $(LOG)
docker save $* | gzip -c > $@
$(FOOTER)