diff options
author | Maciej Kisielewski <maciej.kisielewski@canonical.com> | 2017-11-13 12:34:46 +0100 |
---|---|---|
committer | Maciej Kisielewski <maciej.kisielewski@canonical.com> | 2017-11-13 12:34:46 +0100 |
commit | d4238c8e0577fcdc32659ddf5147348ee8ba57ba (patch) | |
tree | ef78d5580c5545649b91d4bb6614cb546fb8e471 /units/graphics | |
parent | ddb42b371a05ebf256ee8a7c445725d9ead74f53 (diff) |
add automated switch-to-gpu templated job
Signed-off-by: Maciej Kisielewski <maciej.kisielewski@canonical.com>
Diffstat (limited to 'units/graphics')
-rw-r--r-- | units/graphics/jobs.pxu | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/units/graphics/jobs.pxu b/units/graphics/jobs.pxu index a7af65a..468caf7 100644 --- a/units/graphics/jobs.pxu +++ b/units/graphics/jobs.pxu @@ -503,3 +503,18 @@ estimated_duration: 1.0 command: [ -f $PLAINBOX_SESSION_SHARE/screen-capture-{index}.png ] && base64 $PLAINBOX_SESSION_SHARE/screen-capture-{index}.png _description: Attaches the simple screen capture file of {vendor} {product} +unit: template +template-resource: graphics_card +category_id: com.canonical.plainbox::graphics +id: graphics/{index}_auto_switch_card_{product_slug} +requires: + graphics_card.driver in ['nvidia', 'amdgpu-pro'] +_summary: Switch GPU to {vendor} {product} and reboot +_purpose: + Switch GPU to {vendor} {product} and reboot the machine +plugin: shell +user: root +command: + {switch_to_cmd} + pm_test --silent --checkbox-respawn-cmd $PLAINBOX_SESSION_SHARE/__respawn_checkbox reboot --log-level=debug --log-dir=$PLAINBOX_SESSION_SHARE +flags: noreturn preserve-locale |