cmd: update "make hack" #3952

Merged
merged 2 commits into from Sep 22, 2017

Conversation

Projects
None yet
4 participants
Contributor

zyga commented Sep 21, 2017

This fixes common issues when using make hack:

  • snap-seccomp is out-of-date
  • snap-confine.d doesn't exist

zyga added some commits Sep 21, 2017

cmd: create snap-confine.d on "make hack"
The apparmor profile for snap-confine now sources a directory that needs
to exist so create it in make hack.

Signed-off-by: Zygmunt Krynicki <zygmunt.krynicki@canonical.com>
cmd: install snap-seccomp on "make hack"
Typically the locally packaged snap-seccomp binary is out of date and
snapd will re-compile seccomp profiles on startup so it needs to be
updated.

Signed-off-by: Zygmunt Krynicki <zygmunt.krynicki@canonical.com>

mvo5 approved these changes Sep 21, 2017

sudo install -D -m 4755 snap-confine/snap-confine $(DESTDIR)$(libexecdir)/snap-confine
sudo install -m 644 snap-confine/snap-confine.apparmor $(DESTDIR)/etc/apparmor.d/$(patsubst .%,%,$(subst /,.,$(libexecdir))).snap-confine
+ sudo install -d -m 755 $(DESTDIR)/var/lib/snapd/apparmor/snap-confine.d/
@niemeyer

niemeyer Sep 21, 2017

Contributor

I cannot find "snap-confine.d" anywhere in our source code. What is it about?

@zyga

zyga Sep 22, 2017

Contributor

This is a include directory introduced in #3807

Codecov Report

Merging #3952 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #3952   +/-   ##
=======================================
  Coverage   75.93%   75.93%           
=======================================
  Files         420      420           
  Lines       36310    36310           
=======================================
  Hits        27571    27571           
  Misses       6807     6807           
  Partials     1932     1932
Impacted Files Coverage Δ
overlord/ifacestate/helpers.go 62.33% <0%> (-0.67%) ⬇️
cmd/snap-seccomp/main.go 56.87% <0%> (+0.31%) ⬆️
interfaces/sorting.go 100% <0%> (+1.28%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2a8542f...5b6cebe. Read the comment docs.

@mvo5 mvo5 merged commit a12a217 into snapcore:master Sep 22, 2017

7 checks passed

artful-amd64 autopkgtest finished (success)
Details
artful-i386 autopkgtest finished (success)
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
xenial-amd64 autopkgtest finished (success)
Details
xenial-i386 autopkgtest finished (success)
Details
xenial-ppc64el autopkgtest finished (success)
Details
zesty-amd64 autopkgtest finished (success)
Details

@zyga zyga deleted the zyga:tweak/make-hack-improvements branch Sep 25, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment