from auth.backend import MyCustomBackend
from myslice.viewutils import the_user
+from myslice.config import Config
def login_user(request):
state = "Please log in below..."
username = password = ''
- env={'hard_wired_users':MyCustomBackend.hard_wired_users}
-
+ env={'hard_wired_users':MyCustomBackend.hard_wired_users,
+ 'manifold_url':Config.manifold_url(),
+ }
+
if request.POST:
username = request.POST.get('username')
password = request.POST.get('password')
self.trace = []
self.calls = {}
self.multicall = False
- self.url = "http://"+self.server+":"+self.port+"/"
+ self.url = config.manifold_url()
self.proxy = xmlrpclib.Server(self.url, verbose=False, allow_none=True)
def __getattr__(self, methodName):
manifold_server = 'debian04.pl.sophia.inria.fr'
manifold_port = '7080'
manifold_path = '/'
+
+ @staticmethod
+ def manifold_url ():
+ return "http://%s:%s%s"%(Config.manifold_server,Config.manifold_port,Config.manifold_path)
{% endblock content_related %}
{% block content_main %}
-<code>
-This page is currently not connected to any useful authentication system, but instead, as a proof of concept, it uses a set of hardwired user accounts, see auth/backend.py for more details.
-</code>
-<p>Currently hard wired users:</p>
+<code> This page is currently connected to two authentication systems:</code>
+<ul>
+<li> A manifold server, located at <code>{{ manifold_url }}</code>, and</li>
+<li>
+as a proof of concept, a set of hardwired user accounts, see auth/backend.py for more details.
+Currently hard wired users are:
<ul>
{% for k,v in hard_wired_users.iteritems %}
<li class='well'> Name= <code>{{ k }}</code>, Password= <code>{{ v }}</code> </li>
{% endfor %}
</ul>
+</li></ul>
{% endblock content_main %}