Skip to content
Snippets Groups Projects
Commit 5b54e1e7 authored by Filip Strömbäck's avatar Filip Strömbäck
Browse files

Using the new keep-repo-updated-script for the scripts dir in examadm.

parent f16ab085
No related branches found
No related tags found
No related merge requests found
......@@ -84,36 +84,15 @@ class aes::aes_sw {
ensure => "running",
}
exec { 'script-repo-clone':
command => '/usr/bin/git clone --quiet --single-branch --branch master --depth 1 git@gitlab.liu.se:examadm/scripts.git',
exec { 'script-repo-updated':
command => "/opt/utils/update_repo.sh ${examadm_home}/scripts https://oauth2:iAyewr9Jq5E-tnsVrmbj@gitlab.liu.se/examadm/scripts.git master",
cwd => "${examadm_home}",
creates => "${examadm_home}/scripts",
user => "${examadm_user}",
group => "${examadm_group}",
require => File["${examadm_home}/.ssh/known_hosts"],
}
schedule { 'everyday':
period => daily,
range => '01:00 - 04:00',
}
exec { 'script-repo-pull':
command => '/usr/bin/git pull --depth 1',
cwd => "${examadm_home}/scripts",
onlyif => "/usr/bin/test -d ${examadm_home}/scripts/.git",
user => "${examadm_user}",
group => "${examadm_group}",
# schedule => 'everyday',
}
file { "${examadm_home}/.ssh/known_hosts":
ensure => present,
owner => "${examadm_user}",
group => "${examadm_group}",
mode => '0644',
content => @(KNOWNHOST)
gitlab.liu.se,2001:6b0:17:f003::44 ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBF3yWjkuKo7f3OH4BhGwcd71lkWZqdyk7cxOCn5exPoqLldt2OfbhEA7lM+89Gr/AqRbHlbrS1M8An7j4Lj77hc=
| KNOWNHOST
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment