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

cmd/snap-confine: call sc_should_use_normal_mode once #6573

Merged
merged 5 commits into from
Mar 9, 2019

Commits on Mar 6, 2019

  1. cmd/snap-confine: call sc_should_use_normal_mode once

    Historically snap-confine used two modes of operation. Initially on core
    systems snap-confine would unshare the mount namespace and preform some
    alterations but would otherwise run with the contents of the initial
    mount namesapce. On classic systems snap-confine would pivot into the
    base snap (core) and perform some more alterations.
    
    With the introduction of multiple boot bases, per-snap bases some of
    that logic seems rusty. To make it less confusing what is going on
    reduce the number of places that determine if legacy (sans-pivot) or
    normal mode (with pivot) to exactly one.
    
    There is more cleanup that can be done but it will require making the
    invocation structure something we can pass around to more functions.
    This will be attempted in subsequent patches.
    
    Signed-off-by: Zygmunt Krynicki <zygmunt.krynicki@canonical.com>
    zyga committed Mar 6, 2019
    Configuration menu
    Copy the full SHA
    0dec25e View commit details
    Browse the repository at this point in the history
  2. cmd/snap-confine: move is_normal_mode to sc_invocation

    This allows us to almost start passing sc_invocation instead of a
    plethora of arguments to various functions inside ns-support and
    mount-support modules.
    
    This also makes it a tiny bit problematic because is_normal_mode is a
    boolean that is only set inside the non-classic code path. This is
    correct for now but should be carefully changed later.
    
    Signed-off-by: Zygmunt Krynicki <zygmunt.krynicki@canonical.com>
    zyga committed Mar 6, 2019
    Configuration menu
    Copy the full SHA
    c7633e9 View commit details
    Browse the repository at this point in the history

Commits on Mar 7, 2019

  1. Configuration menu
    Copy the full SHA
    66f9912 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    c15994f View commit details
    Browse the repository at this point in the history

Commits on Mar 8, 2019

  1. Configuration menu
    Copy the full SHA
    aef600d View commit details
    Browse the repository at this point in the history