~sylvain-pineau/plainbox:snappy-restart-with-sudo

Last commit made on 2016-11-04
Get this branch:
git clone -b snappy-restart-with-sudo https://git.launchpad.net/~sylvain-pineau/plainbox
Only Sylvain Pineau can upload to this branch. If you are Sylvain Pineau please log in for upload directions.

Branch merges

Branch information

Name:
snappy-restart-with-sudo
Repository:
lp:~sylvain-pineau/plainbox

Recent commits

da7f0fa... by Sylvain Pineau

session:restart: Set up the systemd unit for all-snaps using sudo

Ubuntu Core 16 users have a sudoers configuration allowing sudo usage without
a password. Stress tests requiring a system restart had to run checkbox with
sudo to be able to set up the systemd unit, making all logs and report owned
by root (and saved in SNAP_DATA instead of SNAP_USER_DATA).

The new version takes advantage of this sudoer config by calling sudo from plainbox,
this allowing the whole session to be controlled by the user account.

The benefits are threefold, we stop using sudo to run stress tests, all logs
are easily accessible from SNAP_DATA and we don't need a specific snapcraft
launcher wrapper for stress tests.

7bd552e... by Sylvain Pineau

Merge branch 'master' of git+ssh://git.launchpad.net/plainbox

1d21b5d... by Sylvain Pineau

exporter:json: Add recovery/bto/buildstamp info to the report template

aa400a9... by PMR <pmr@pmr-lander>

Merge #309252 from ~sylvain-pineau/plainbox:jinja2_template_units

e6e009a... by Sylvain Pineau

Add support for Jinja2 in template units

Just add the following line to start using the Jinja2 template syntax.
Example:

unit: template
template-resource: device
template-filter: device.category == 'NETWORK'
template-engine: jinja2
id: ethernet/hotplug-{{ interface }}-check-disconnected
[...]
after:
 {%- if __index__ > 1 %}ethernet/hotplug-{{ __index__ - 1 }}-end-cycle{%- endif %}

1529097... by PMR <pmr@pmr-lander>

Merge #309085 from ~sylvain-pineau/plainbox:add_python_vars_in_diff_env_snappy

df0735b... by Sylvain Pineau

Fix the differential execution environment on snappy to preserve python specific vars

On snappy (as of UC16), to run the bundled python3 interpreter and find the right
set of modules, snappy sets two env var, namely PYTHONHOME and PYTHONUSERBASE.

When the plainbox sudo controller computes the differential execution environment,
it needs to retain both in the final env.

6c53162... by PMR <pmr@pmr-lander>

Merge #309022 from ~sylvain-pineau/plainbox:fix_sudo_controller_snappy

1d1a190... by Sylvain Pineau

Update the sudo controller alg to also check /etc/sudoers.d on snappy

6b72081... by PMR <pmr@pmr-lander>

Merge #308796 from ~sylvain-pineau/plainbox:new_json_exporter_po_fix