Commit c4dd0be8 authored by Daniel W Bond's avatar Daniel W Bond

moved the peoplefinder api url to the settings file

parent f8ad3f66
...@@ -4,11 +4,12 @@ from django.contrib.auth.models import User ...@@ -4,11 +4,12 @@ from django.contrib.auth.models import User
# third-part imports # third-part imports
import requests import requests
# imports from your apps # imports from your apps
from django.conf import settings
from .models import Student from .models import Student
def pfinfo(u_name): def pfinfo(u_name):
pf_url = "http://peoplefinder.b1.akshaykarthik.com/" pf_url = settings.PF_URL
url = str(pf_url) + "basic/all/" + str(u_name) url = str(pf_url) + "basic/all/" + str(u_name)
try: try:
metadata = requests.get(url) metadata = requests.get(url)
......
...@@ -112,6 +112,9 @@ AUTHENTICATION_BACKENDS = ( ...@@ -112,6 +112,9 @@ AUTHENTICATION_BACKENDS = (
'cas.backends.CASBackend', 'cas.backends.CASBackend',
) )
# Peoplefinder API for user creation
PF_URL = "http://peoplefinder.b1.akshaykarthik.com/"
CAS_SERVER_URL = 'https://login.gmu.edu' CAS_SERVER_URL = 'https://login.gmu.edu'
CAS_LOGOUT_COMPLETELY = True CAS_LOGOUT_COMPLETELY = True
CAS_PROVIDE_URL_TO_LOGOUT = True CAS_PROVIDE_URL_TO_LOGOUT = True
......
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