Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Aurel
slapos
Commits
e94e163d
Commit
e94e163d
authored
Jun 10, 2015
by
Ayush Tiwari
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
IPynb: Added notebook software type in the IPython Notebook software release
parent
71e2082c
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
187 additions
and
167 deletions
+187
-167
software/ipython_notebook/instance-ipython-default.cfg.in
software/ipython_notebook/instance-ipython-default.cfg.in
+10
-164
software/ipython_notebook/instance-ipython-notebook.cfg.in
software/ipython_notebook/instance-ipython-notebook.cfg.in
+165
-0
software/ipython_notebook/instance.cfg
software/ipython_notebook/instance.cfg
+2
-1
software/ipython_notebook/software.cfg
software/ipython_notebook/software.cfg
+10
-2
No files found.
software/ipython_notebook/instance-ipython-default.cfg.in
View file @
e94e163d
[buildout]
[buildout]
parts =
extends =
instance
${template-ipynb:output}
publish-connection-parameter
## Monitoring part XXX whe should not have to specify all parts like this
[request-ipynb]
## Parts to add for monitoring
<= slap-connection
certificate-authority
recipe = slapos.cookbook:request
cron
name = IPython Notebook
cron-entry-monitor
software-url = $${slap-connection:software-release-url}
cron-entry-rss
software-type = notebook
deploy-index
return = url
deploy-settings-cgi
deploy-status-cgi
deploy-status-history-cgi
setup-static-files
certificate-authority
zero-parameters
public-symlink
cgi-httpd-wrapper
cgi-httpd-graceful-wrapper
monitor-promise
monitor-instance-log-access
## Monitor for ipython
monitor-current-log-access
monitor-deploy-set-password-cgi
erp5-kernel
kernel-json
extends = ${monitor-template:output}
eggs-directory = ${buildout:eggs-directory}
develop-eggs-directory = ${buildout:develop-eggs-directory}
offline = true
[slapconfiguration]
recipe = slapos.cookbook:slapconfiguration
computer = $${slap-connection:computer-id}
partition = $${slap-connection:partition-id}
url = $${slap-connection:server-url}
key = $${slap-connection:key-file}
cert = $${slap-connection:cert-file}
configuration.erp5_url = https://softinst60318.host.vifib.net/erp5/Base_executePython
[jinja2-template-base]
recipe = slapos.recipe.template:jinja2
rendered = $${buildout:directory}/$${:filename}
extra-context =
context =
import json_module json
key eggs_directory buildout:eggs-directory
key develop_eggs_directory buildout:develop-eggs-directory
key slap_software_type slap-parameters:slap-software-type
key slapparameter_dict slap-parameters:configuration
key slave_instance_list slap-parameters:slave-instance-list
$${:extra-context}
[instance-parameter]
port = 8888
host = $${slapconfiguration:ipv6-random}
cert_file = $${generate-certificate:cert_file}
key_file = $${generate-certificate:key_file}
logfile = $${directory:log}/ipython_notebook.log
notebook_dir = $${directory:notebook_dir}
[generate-certificate]
; TODO: there is a slapos recipe to generate certificates. Use it instead
recipe = plone.recipe.command
command =
if [ ! -e $${instance-parameter:key_file} ]
then
${openssl-output:openssl} req -x509 -nodes -days 3650 \
-subj "/C=AA/ST=X/L=X/O=Dis/CN=$${instance-parameter:host}" \
-newkey rsa:1024 -keyout $${instance-parameter:key_file} \
-out $${instance-parameter:cert_file}
fi
update-command = $${:command}
cert_file = $${directory:etc}/ipython_notebook_cert.crt
key_file = $${directory:etc}/ipython_notebook_cert.key
[instance]
recipe = slapos.cookbook:wrapper
command-line =
${buildout:bin-directory}/ipython notebook
--no-browser
--matplotlib=inline
--ip=$${instance-parameter:host}
--port=$${instance-parameter:port}
--port-retries=0
--certfile=$${instance-parameter:cert_file}
--keyfile=$${instance-parameter:key_file}
--notebook-dir=$${instance-parameter:notebook_dir}
--logfile=$${instance-parameter:logfile}
--config=$${ipython_notebook_config:rendered}
## Adding log-level as parameter is only for development process
## and would be removed later.
--log-level="DEBUG"
wrapper-path = $${directory:service}/ipython_notebook
parameters-extra = true
environment = IPYTHONDIR=$${directory:ipython_dir}
[ipython_notebook_config]
recipe = slapos.recipe.template:jinja2
template = ${ipython_notebook_config:location}/${ipython_notebook_config:filename}
rendered = $${directory:etc}/ipython_notebook_config.py
mode = 0744
context =
raw config_cfg $${buildout:directory}/knowledge0.cfg
raw ipython_dir $${directory:ipython_dir}
[monitor-current-log-access]
< = monitor-directory-access
source = $${instance-parameter:logfile}
[monitor-deploy-set-password-cgi]
recipe = slapos.recipe.template:jinja2
template = ${ipython_notebook_set_password:location}/${ipython_notebook_set_password:filename}
rendered = $${monitor-directory:knowledge0-cgi}/$${:filename}
filename = ipython-notebook-password.cgi
mode = 0744
context =
raw config_cfg $${buildout:directory}/knowledge0.cfg
raw python_executable ${buildout:bin-directory}/ipython
key pwd monitor-directory:knowledge0-cgi
key this_file :filename
key httpd_graceful cgi-httpd-graceful-wrapper:rendered
[directory]
recipe = slapos.cookbook:mkdirectory
home = $${buildout:directory}
etc = $${:home}/etc
var = $${:home}/var
script = $${:etc}/run/
service = $${:etc}/service
promise = $${:etc}/promise/
log = $${:var}/log
notebook_dir = $${:var}/notebooks
ipython_dir = $${:home}/ipython
ipython_kernel_dir = $${:ipython_dir}/kernels
erp5_kernel_dir = $${:ipython_kernel_dir}/ERP5
[publish-connection-parameter]
recipe = slapos.cookbook:publish
url = https://[$${instance-parameter:host}]:$${instance-parameter:port}
monitor_url = $${monitor-parameters:url}
erp5_url = $${slapconfiguration:configuration.erp5_url}
[erp5-kernel]
recipe = slapos.recipe.template:jinja2
template = ${erp5-kernel:location}/${erp5-kernel:filename}
rendered = $${directory:erp5_kernel_dir}/ERP5kernel.py
mode = 0744
context =
raw python_executable ${buildout:bin-directory}/pythonwitheggs
key erp5_url slapconfiguration:configuration.erp5_url
[kernel-json]
recipe = slapos.recipe.template:jinja2
template = ${kernel-json:location}/${kernel-json:filename}
rendered = $${directory:erp5_kernel_dir}/kernel.json
mode = 0744
context =
raw python_executable ${buildout:bin-directory}/pythonwitheggs
key kernel_dir erp5-kernel:rendered
raw display_name ERP5
raw language_name python
software/ipython_notebook/instance-ipython-notebook.cfg.in
0 → 100644
View file @
e94e163d
[buildout]
parts =
instance
publish-connection-parameter
## Monitoring part XXX whe should not have to specify all parts like this
## Parts to add for monitoring
certificate-authority
cron
cron-entry-monitor
cron-entry-rss
deploy-index
deploy-settings-cgi
deploy-status-cgi
deploy-status-history-cgi
setup-static-files
certificate-authority
zero-parameters
public-symlink
cgi-httpd-wrapper
cgi-httpd-graceful-wrapper
monitor-promise
monitor-instance-log-access
## Monitor for ipython
monitor-current-log-access
monitor-deploy-set-password-cgi
erp5-kernel
kernel-json
extends = ${monitor-template:output}
eggs-directory = ${buildout:eggs-directory}
develop-eggs-directory = ${buildout:develop-eggs-directory}
offline = true
[slapconfiguration]
recipe = slapos.cookbook:slapconfiguration
computer = $${slap-connection:computer-id}
partition = $${slap-connection:partition-id}
url = $${slap-connection:server-url}
key = $${slap-connection:key-file}
cert = $${slap-connection:cert-file}
configuration.erp5_url = https://softinst60318.host.vifib.net/erp5/Base_executePython
[jinja2-template-base]
recipe = slapos.recipe.template:jinja2
rendered = $${buildout:directory}/$${:filename}
extra-context =
context =
import json_module json
key eggs_directory buildout:eggs-directory
key develop_eggs_directory buildout:develop-eggs-directory
key slap_software_type slap-parameters:slap-software-type
key slapparameter_dict slap-parameters:configuration
key slave_instance_list slap-parameters:slave-instance-list
$${:extra-context}
[instance-parameter]
port = 8888
host = $${slapconfiguration:ipv6-random}
cert_file = $${generate-certificate:cert_file}
key_file = $${generate-certificate:key_file}
logfile = $${directory:log}/ipython_notebook.log
notebook_dir = $${directory:notebook_dir}
[generate-certificate]
; TODO: there is a slapos recipe to generate certificates. Use it instead
recipe = plone.recipe.command
command =
if [ ! -e $${instance-parameter:key_file} ]
then
${openssl-output:openssl} req -x509 -nodes -days 3650 \
-subj "/C=AA/ST=X/L=X/O=Dis/CN=$${instance-parameter:host}" \
-newkey rsa:1024 -keyout $${instance-parameter:key_file} \
-out $${instance-parameter:cert_file}
fi
update-command = $${:command}
cert_file = $${directory:etc}/ipython_notebook_cert.crt
key_file = $${directory:etc}/ipython_notebook_cert.key
[instance]
recipe = slapos.cookbook:wrapper
command-line =
${buildout:bin-directory}/ipython notebook
--no-browser
--matplotlib=inline
--ip=$${instance-parameter:host}
--port=$${instance-parameter:port}
--port-retries=0
--certfile=$${instance-parameter:cert_file}
--keyfile=$${instance-parameter:key_file}
--notebook-dir=$${instance-parameter:notebook_dir}
--logfile=$${instance-parameter:logfile}
--config=$${ipython_notebook_config:rendered}
## Adding log-level as parameter is only for development process
## and would be removed later.
--log-level="DEBUG"
wrapper-path = $${directory:service}/ipython_notebook
parameters-extra = true
environment = IPYTHONDIR=$${directory:ipython_dir}
[ipython_notebook_config]
recipe = slapos.recipe.template:jinja2
template = ${ipython_notebook_config:location}/${ipython_notebook_config:filename}
rendered = $${directory:etc}/ipython_notebook_config.py
mode = 0744
context =
raw config_cfg $${buildout:directory}/knowledge0.cfg
raw ipython_dir $${directory:ipython_dir}
[monitor-current-log-access]
< = monitor-directory-access
source = $${instance-parameter:logfile}
[monitor-deploy-set-password-cgi]
recipe = slapos.recipe.template:jinja2
template = ${ipython_notebook_set_password:location}/${ipython_notebook_set_password:filename}
rendered = $${monitor-directory:knowledge0-cgi}/$${:filename}
filename = ipython-notebook-password.cgi
mode = 0744
context =
raw config_cfg $${buildout:directory}/knowledge0.cfg
raw python_executable ${buildout:bin-directory}/ipython
key pwd monitor-directory:knowledge0-cgi
key this_file :filename
key httpd_graceful cgi-httpd-graceful-wrapper:rendered
[directory]
recipe = slapos.cookbook:mkdirectory
home = $${buildout:directory}
etc = $${:home}/etc
var = $${:home}/var
script = $${:etc}/run/
service = $${:etc}/service
promise = $${:etc}/promise/
log = $${:var}/log
notebook_dir = $${:var}/notebooks
ipython_dir = $${:home}/ipython
ipython_kernel_dir = $${:ipython_dir}/kernels
erp5_kernel_dir = $${:ipython_kernel_dir}/ERP5
[publish-connection-parameter]
recipe = slapos.cookbook:publish
url = https://[$${instance-parameter:host}]:$${instance-parameter:port}
monitor_url = $${monitor-parameters:url}
erp5_url = $${slapconfiguration:configuration.erp5_url}
[erp5-kernel]
recipe = slapos.recipe.template:jinja2
template = ${erp5-kernel:location}/${erp5-kernel:filename}
rendered = $${directory:erp5_kernel_dir}/ERP5kernel.py
mode = 0744
context =
raw python_executable ${buildout:bin-directory}/pythonwitheggs
key erp5_url slapconfiguration:configuration.erp5_url
[kernel-json]
recipe = slapos.recipe.template:jinja2
template = ${kernel-json:location}/${kernel-json:filename}
rendered = $${directory:erp5_kernel_dir}/kernel.json
mode = 0744
context =
raw python_executable ${buildout:bin-directory}/pythonwitheggs
key kernel_dir erp5-kernel:rendered
raw display_name ERP5
raw language_name python
software/ipython_notebook/instance.cfg
View file @
e94e163d
...
@@ -8,4 +8,5 @@ offline = true
...
@@ -8,4 +8,5 @@ offline = true
[switch-softwaretype]
[switch-softwaretype]
recipe = slapos.cookbook:softwaretype
recipe = slapos.cookbook:softwaretype
default = ${template-ipynb:output}
default = ${default-template-ipynb:output}
notebook = ${template-ipynb:output}
\ No newline at end of file
software/ipython_notebook/software.cfg
View file @
e94e163d
...
@@ -16,6 +16,7 @@ parts =
...
@@ -16,6 +16,7 @@ parts =
ipython_notebook_set_password
ipython_notebook_set_password
instance
instance
template-ipynb
template-ipynb
default-template-ipynb
[ipython_notebook]
[ipython_notebook]
; In the ipython notebook software, we use more eggs than in the minimal
; In the ipython notebook software, we use more eggs than in the minimal
...
@@ -54,9 +55,16 @@ output = ${buildout:directory}/instance.cfg
...
@@ -54,9 +55,16 @@ output = ${buildout:directory}/instance.cfg
[template-ipynb]
[template-ipynb]
recipe = slapos.recipe.template
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-ipython-
default
.cfg.in
url = ${:_profile_base_location_}/instance-ipython-
notebook
.cfg.in
md5sum = 5ba2484c3550a3254d14fcf1ed5fa6f4
md5sum = 5ba2484c3550a3254d14fcf1ed5fa6f4
output = ${buildout:directory}/template-ipython.cfg
output = ${buildout:directory}/template-ipython-notebook.cfg
mode = 0644
[default-template-ipynb]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-ipython-default.cfg.in
md5sum = bd573c4ab5e1893d3bf91ae5c7c0d792
output = ${buildout:directory}/temlate-ipython-default.cfg.in
mode = 0644
mode = 0644
[erp5-kernel]
[erp5-kernel]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment