diff options
author | Tony Sarajärvi <tony.sarajarvi@digia.com> | 2014-03-20 11:32:02 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-03-20 10:40:01 +0100 |
commit | 62c1da645b1a262953ac21ba0873737654276ceb (patch) | |
tree | e0f7286bb631766a872a092288b4a64159c9a744 /puppet | |
parent | b82da072bbfa63e1b74eeddde7e6d079c1bc3938 (diff) |
New QNX puppet module
Installs QNX's SDP to our Ubuntus.
Change-Id: Ic5d8f5040016f2ff485215d1381af47b84771d44
Reviewed-by: Sergio Ahumada <sahumada@blackberry.com>
Diffstat (limited to 'puppet')
-rw-r--r-- | puppet/modules/ci_tester/manifests/linux.pp | 1 | ||||
-rw-r--r-- | puppet/modules/qnx/manifests/init.pp | 6 | ||||
-rw-r--r-- | puppet/modules/qnx/manifests/linux.pp | 33 | ||||
-rw-r--r-- | puppet/modules/qnx/tests/qnx.pp | 3 |
4 files changed, 43 insertions, 0 deletions
diff --git a/puppet/modules/ci_tester/manifests/linux.pp b/puppet/modules/ci_tester/manifests/linux.pp index 89ffbe6..5264fc0 100644 --- a/puppet/modules/ci_tester/manifests/linux.pp +++ b/puppet/modules/ci_tester/manifests/linux.pp @@ -2,6 +2,7 @@ class ci_tester::linux inherits ci_tester::base { include ccache include crosscompilers include android + include qnx if $ci_tester::vmware_enabled { include vmware_tools diff --git a/puppet/modules/qnx/manifests/init.pp b/puppet/modules/qnx/manifests/init.pp new file mode 100644 index 0000000..0d8c209 --- /dev/null +++ b/puppet/modules/qnx/manifests/init.pp @@ -0,0 +1,6 @@ +class qnx { + case $::operatingsystem { + Ubuntu: { include qnx::linux } + } +} + diff --git a/puppet/modules/qnx/manifests/linux.pp b/puppet/modules/qnx/manifests/linux.pp new file mode 100644 index 0000000..96d8c3d --- /dev/null +++ b/puppet/modules/qnx/manifests/linux.pp @@ -0,0 +1,33 @@ +# Download and unzip QNX SDP to $target. Update will be done and +# old version will be removed if $filename is changed to point to new or older version. +class qnx::linux +{ + $url = "$input/qnx" + $filename = "qnx660.tar.gz" + $target = "/opt" + + file { "$target": + ensure => directory, + owner => root, + group => users, + mode => 0755, + } + + define qnx_install($filename,$options,$target,$url) { + exec { "install ${filename} to ${target}": + command => "/bin/bash -c 'wget $url/$filename -O - | tar -C $target -$options'", + unless => "/bin/bash -c 'if [ -e ${target} ]'", + require => File["$target"], + timeout => 1800, + } + } + + qnx_install { + "sdp": + filename => "$filename", + options => "xz", + target => "$target", + url => "$url", + ; + } +} diff --git a/puppet/modules/qnx/tests/qnx.pp b/puppet/modules/qnx/tests/qnx.pp new file mode 100644 index 0000000..1312d5f --- /dev/null +++ b/puppet/modules/qnx/tests/qnx.pp @@ -0,0 +1,3 @@ +include qnx + +selftest::expect_no_warnings { "no warnings from qnx": } |