Prepare for persistent volumes
This commit is contained in:
parent
41218a4216
commit
b01126104d
@ -1,3 +0,0 @@
|
|||||||
FROM sahana:latest
|
|
||||||
|
|
||||||
VOLUME ["/srv/web2py/applications/eden/models"]
|
|
@ -5,5 +5,3 @@ COPY image.d /
|
|||||||
RUN \
|
RUN \
|
||||||
# Change ownership of the newly copied files
|
# Change ownership of the newly copied files
|
||||||
find /srv/web2py ! -user sahana -exec chown -R sahana:sahana {} +
|
find /srv/web2py ! -user sahana -exec chown -R sahana:sahana {} +
|
||||||
|
|
||||||
VOLUME ["/srv/web2py/applications/eden/models"]
|
|
||||||
|
@ -5,5 +5,3 @@ COPY image.d /
|
|||||||
RUN \
|
RUN \
|
||||||
# Change ownership of the newly copied files
|
# Change ownership of the newly copied files
|
||||||
find /srv/web2py ! -user sahana -exec chown -R sahana:sahana {} +
|
find /srv/web2py ! -user sahana -exec chown -R sahana:sahana {} +
|
||||||
|
|
||||||
VOLUME ["/srv/web2py/applications/eden/models"]
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="{{=T.accepted_language or "en"}}">{{# class="no-js" needed for modernizr }}
|
<html xmlns="http://www.w3.org/1999/xhtml" class="no-js" lang="{{=T.accepted_language or "en"}}">
|
||||||
<head>{{theme_styles=response.s3.theme_styles}}
|
<head>{{theme_styles=response.s3.theme_styles}}
|
||||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||||
{{# Always force latest IE rendering engine (even in intranet) & Chrome Frame }}
|
{{# Always force latest IE rendering engine (even in intranet) & Chrome Frame }}
|
||||||
@ -52,17 +52,14 @@
|
|||||||
{{else:}}
|
{{else:}}
|
||||||
<body>
|
<body>
|
||||||
<header>
|
<header>
|
||||||
<div class="fixed">
|
{{=current.menu.main}}
|
||||||
{{=current.menu.main}}
|
|
||||||
</div>
|
|
||||||
</header>
|
</header>
|
||||||
<main role="main" class="main">
|
<main role='main' class='main'>
|
||||||
<div class='row'>
|
<div class='row'>
|
||||||
{{if current.menu.options is not None:}}
|
{{if current.menu.options is not None:}}
|
||||||
<a id='menu-options-toggle' class='tiny secondary button show-for-small' data-status='off' data-off='{{=T("Show Options")}}' data-on='{{=T("Hide Options")}}'>{{=T("Show Options")}}</a>
|
<aside class='medium-3 large-2 columns hide-for-small' id='menu-options'>
|
||||||
<div class='medium-3 large-2 columns hide-for-small' id='menu-options'>
|
|
||||||
{{=current.menu.options}}
|
{{=current.menu.options}}
|
||||||
</div>
|
</aside>
|
||||||
<div class='medium-9 large-10 columns' id='content'>
|
<div class='medium-9 large-10 columns' id='content'>
|
||||||
{{else:}}
|
{{else:}}
|
||||||
<div class='medium-12 columns' id='content'>
|
<div class='medium-12 columns' id='content'>
|
||||||
@ -81,13 +78,13 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</main>
|
</main>
|
||||||
<footer role="complementary" class="footer">
|
<footer role='complementary' class='footer'>
|
||||||
<div class='row' id='footer'>
|
<div class='row' id='footer'>
|
||||||
<div class='medium-12 columns'>
|
<div class='medium-12 columns'>
|
||||||
{{include "../modules/templates/%s/views/footer.html" % response.s3.theme_layouts}}
|
{{include "../modules/templates/%s/views/footer.html" % response.s3.theme_layouts}}
|
||||||
{{if s3.debug:}}
|
{{if s3.debug:}}
|
||||||
<div class="row">
|
<div class='row'>
|
||||||
<div class='medium-12 columns'>{{=s3.toolbar()}}</div>
|
<div class='medium-12 columns'>{{=s3base.s3_dev_toolbar()}}</div>
|
||||||
</div>
|
</div>
|
||||||
{{pass}}
|
{{pass}}
|
||||||
</div>
|
</div>
|
||||||
|
@ -54,6 +54,4 @@ RUN \
|
|||||||
|
|
||||||
ENTRYPOINT ["/entrypoint.sh"]
|
ENTRYPOINT ["/entrypoint.sh"]
|
||||||
EXPOSE 8080
|
EXPOSE 8080
|
||||||
# VOLUME /srv/web2py/applications/eden/models not declared here to allow volume data overrides
|
|
||||||
# Specifying it here would cause any subsequent changes under the volume path (such as changes to 000_config.py) to be discarded
|
|
||||||
VOLUME ["/srv/web2py/applications/eden/databases", "/srv/web2py/applications/eden/errors", "/srv/web2py/applications/eden/sessions", "/srv/web2py/applications/eden/uploads"]
|
VOLUME ["/srv/web2py/applications/eden/databases", "/srv/web2py/applications/eden/errors", "/srv/web2py/applications/eden/sessions", "/srv/web2py/applications/eden/uploads"]
|
||||||
|
@ -7,6 +7,13 @@ fi
|
|||||||
|
|
||||||
echo "Starting Sahana Eden..."
|
echo "Starting Sahana Eden..."
|
||||||
|
|
||||||
|
# Fix volume permissions
|
||||||
|
chown -R sahana:sahana \
|
||||||
|
/srv/web2py/applications/eden/databases \
|
||||||
|
/srv/web2py/applications/eden/errors \
|
||||||
|
/srv/web2py/applications/eden/sessions \
|
||||||
|
/srv/web2py/applications/eden/uploads
|
||||||
|
|
||||||
# Create admin user CSV template
|
# Create admin user CSV template
|
||||||
cat <<EOF >/srv/web2py/applications/eden/modules/templates/default/users/masterUsers.csv
|
cat <<EOF >/srv/web2py/applications/eden/modules/templates/default/users/masterUsers.csv
|
||||||
First Name,Last Name,Email,Password,Role,Organisation
|
First Name,Last Name,Email,Password,Role,Organisation
|
||||||
|
Loading…
Reference in New Issue
Block a user