Commit 0faefdeb authored by Nicolas Wavrant's avatar Nicolas Wavrant

slaprunner: dropbear is now configured by a bash_profile file

parent 6a46279d
...@@ -44,7 +44,7 @@ mode = 0644 ...@@ -44,7 +44,7 @@ mode = 0644
recipe = slapos.recipe.template recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-runner.cfg url = ${:_profile_base_location_}/instance-runner.cfg
output = ${buildout:directory}/template-runner.cfg.in output = ${buildout:directory}/template-runner.cfg.in
md5sum = 9878115a2969489b57e8563ef3d4d6d3 md5sum = 3ec889957be037fbc7f0f0c68b5d532a
mode = 0644 mode = 0644
[template-runner-import-script] [template-runner-import-script]
...@@ -59,7 +59,7 @@ mode = 0644 ...@@ -59,7 +59,7 @@ mode = 0644
recipe = slapos.recipe.template recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-runner-import.cfg.in url = ${:_profile_base_location_}/instance-runner-import.cfg.in
output = ${buildout:directory}/instance-runner-import.cfg output = ${buildout:directory}/instance-runner-import.cfg
md5sum = 354ff83819e8379f5e4a2e2985e34e9e md5sum = 78105b34f9f1d884e291104a711e43f4
mode = 0644 mode = 0644
[template-runner-export-script] [template-runner-export-script]
...@@ -74,7 +74,7 @@ mode = 0644 ...@@ -74,7 +74,7 @@ mode = 0644
recipe = slapos.recipe.template recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-runner-export.cfg.in url = ${:_profile_base_location_}/instance-runner-export.cfg.in
output = ${buildout:directory}/instance-runner-export.cfg output = ${buildout:directory}/instance-runner-export.cfg
md5sum = 6930a0d6c88896c43a8e60509ba6bd1c md5sum = 41180970d3ec6decdf946bdefc32a809
mode = 0644 mode = 0644
[template-resilient] [template-resilient]
......
...@@ -45,6 +45,7 @@ parts += ...@@ -45,6 +45,7 @@ parts +=
cgi-httpd-graceful-wrapper cgi-httpd-graceful-wrapper
monitor-promise monitor-promise
monitor-instance-log-access monitor-instance-log-access
bash-profile
## Monitor for runner ## Monitor for runner
monitor-current-log-access monitor-current-log-access
monitor-check-resilient-feed-file monitor-check-resilient-feed-file
......
...@@ -24,6 +24,7 @@ parts += ...@@ -24,6 +24,7 @@ parts +=
cron-entry-prepare-software cron-entry-prepare-software
deploy-instance-parameters deploy-instance-parameters
instance-software-type instance-software-type
bash-profile
# have to repeat the next one, as it's not inherited from pbsready-import # have to repeat the next one, as it's not inherited from pbsready-import
import-on-notification import-on-notification
## Monitoring part ## Monitoring part
...@@ -82,4 +83,4 @@ rendered = $${monitor-directory:monitoring-cgi}/latest-restored-backup ...@@ -82,4 +83,4 @@ rendered = $${monitor-directory:monitoring-cgi}/latest-restored-backup
template = ${template-wrapper:output} template = ${template-wrapper:output}
mode = 744 mode = 744
context = context =
key content :command key content :command
\ No newline at end of file
...@@ -24,6 +24,7 @@ parts = ...@@ -24,6 +24,7 @@ parts =
deploy-instance-parameters deploy-instance-parameters
instance-software-type instance-software-type
minishell-cwd minishell-cwd
bash-profile
{% if slapparameter_dict.get('custom-frontend-backend-url') %} {% if slapparameter_dict.get('custom-frontend-backend-url') %}
custom-frontend-promise custom-frontend-promise
{% endif %} {% endif %}
...@@ -219,7 +220,7 @@ keygen-binary = ${dropbear:location}/bin/dropbearkey ...@@ -219,7 +220,7 @@ keygen-binary = ${dropbear:location}/bin/dropbearkey
recipe = slapos.cookbook:dropbear recipe = slapos.cookbook:dropbear
host = $${slap-network-information:global-ipv6} host = $${slap-network-information:global-ipv6}
port = 22222 port = 22222
home = $${directory:ssh} home = $${buildout:directory}
wrapper = $${directory:bin}/runner_sshd wrapper = $${directory:bin}/runner_sshd
shell = ${bash:location}/bin/bash shell = ${bash:location}/bin/bash
rsa-keyfile = $${directory:ssh}/server_key.rsa rsa-keyfile = $${directory:ssh}/server_key.rsa
...@@ -610,6 +611,12 @@ command = if [ ! -f $${slaprunner:minishell_cwd_file} ]; then echo $${runnerdire ...@@ -610,6 +611,12 @@ command = if [ ! -f $${slaprunner:minishell_cwd_file} ]; then echo $${runnerdire
location = $${slaprunner:minishell_cwd_file} location = $${slaprunner:minishell_cwd_file}
stop-on-error = true stop-on-error = true
[bash-profile]
recipe = plone.recipe.command
command = if [ ! -f $${:location} ]; then echo "cd $${runnerdirectory:home}" > $${:location}; fi
location = $${buildout:directory}/.bash_profile
stop-on-error = true
[monitor-current-log-access] [monitor-current-log-access]
< = monitor-directory-access < = monitor-directory-access
source = $${directory:log} source = $${directory:log}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment