Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
zoe
main
Commits
4dcb84c1
Commit
4dcb84c1
authored
Sep 08, 2015
by
Daniele Venzano
Browse files
Update README
parent
bbaa5e8b
Changes
2
Hide whitespace changes
Inline
Side-by-side
README.md
View file @
4dcb84c1
...
...
@@ -13,14 +13,15 @@ It is composed of three components:
*
MySQL to keep all the state
*
Docker Swarm
*
A Docker registry containing Spark images
*
Redis
*
Apache to act as a reverse proxy
## Configuration
Zoe configuration is kept, for now, in a Python file:
`common/configuration.py`
Zoe configuration is read from an 'ini' file, the following locations are searched for a file names
`zoe.conf`
:
*
working path (.)
*
/etc/zoe
The cookie secret key is defined
in
`zoe
_web/__init__.py`
.
A sample configuration file, containing default values for all options can be generated by runn
in
g
`zoe
ctl.py write-conf zoe.conf`
### Swarm/Docker
...
...
@@ -45,11 +46,6 @@ bypassing the Hub.
The images are quite standard and can be used also without Zoe, for examples
on how to do that, see the
`scripts/start_cluster.sh`
script.
### Redis
Redis is used for storing Spark applications and logs, in zip archives. It is not the best use of redis, but it provides a
very simple to use interface. We are looking for a different solution and this requirement will likely disappear soon.
### Apache configuration
Zoe generates dynamically proxy entries to let users access to the various web interfaces contained in the Spark containers.
...
...
zoe_web/web/old_web.py
deleted
100644 → 0
View file @
bbaa5e8b
from
flask
import
render_template
,
redirect
,
url_for
,
abort
from
zoe_web
import
app
from
zoe_client
import
ZoeClient
@
app
.
route
(
"/web/<int:user_id>/cluster/<int:app_id>/inspect"
)
def
web_inspect
(
user_id
,
app_id
):
client
=
ZoeClient
()
if
not
client
.
user_check
(
user_id
):
return
redirect
(
url_for
(
'index'
))
application
=
client
.
application_get
(
app_id
)
if
application
.
user_id
!=
user_id
:
abort
(
404
)
app_report
=
client
.
application_status
(
app_id
)
template_vars
=
{
"application"
:
app_report
,
"user_id"
:
user_id
}
return
render_template
(
'inspect.html'
,
**
template_vars
)
@
app
.
route
(
"/web/<int:user_id>/container/<int:container_id>/logs"
)
def
web_logs
(
user_id
,
container_id
):
client
=
ZoeClient
()
if
not
client
.
user_check
(
user_id
):
return
redirect
(
url_for
(
'index'
))
cont
=
client
.
container_get
(
container_id
)
if
user_id
!=
cont
[
"user_id"
]:
abort
(
404
)
logs
=
client
.
log_get
(
container_id
)
if
logs
is
None
:
abort
(
404
)
else
:
ret
=
{
'user_id'
:
user_id
,
'cont_contents'
:
cont
[
'contents'
],
"cont_logs"
:
logs
}
return
render_template
(
'logs.html'
,
**
ret
)
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