diff --git a/bothub/health/checks.py b/bothub/health/checks.py index 2becb5ab..47420712 100644 --- a/bothub/health/checks.py +++ b/bothub/health/checks.py @@ -29,11 +29,11 @@ def check_database_connection(**kwargs): def check_accessible_api(request, **kwargs): import requests - logger.info('requesting {}'.format(CHECK_ACCESSIBLE_API_URL)) if CHECK_ACCESSIBLE_API_URL: + logger.info('requesting {}'.format(CHECK_ACCESSIBLE_API_URL)) response = requests.get(CHECK_ACCESSIBLE_API_URL) else: - url = 'http://{}/api/repositories/'.format( + url = 'http://{}/200/'.format( request.META.get('HTTP_HOST')) logger.info('requesting to {}'.format(url)) response = requests.get(url) diff --git a/bothub/health/tests.py b/bothub/health/tests.py deleted file mode 100644 index e4defabc..00000000 --- a/bothub/health/tests.py +++ /dev/null @@ -1 +0,0 @@ -# from django.test import TestCase diff --git a/bothub/health/views.py b/bothub/health/views.py index 3025944a..3b77dbf4 100644 --- a/bothub/health/views.py +++ b/bothub/health/views.py @@ -32,3 +32,7 @@ def ping(request): content=content, content_type='text/plain', status=status_code) + + +def r200(request): + return HttpResponse() diff --git a/bothub/urls.py b/bothub/urls.py index 929f0c92..ae2682c4 100644 --- a/bothub/urls.py +++ b/bothub/urls.py @@ -5,6 +5,7 @@ from bothub.api.routers import router as bothub_api_routers from bothub.health.views import ping +from bothub.health.views import r200 from bothub.common.views import download_bot_data @@ -14,6 +15,7 @@ path('docs/', include_docs_urls(title='API Documentation')), path('admin/', admin.site.urls), path('ping/', ping, name='ping'), + path('200/', r200, name='200'), path( 'downloadbotdata//', download_bot_data, diff --git a/setup.py b/setup.py index 6a9ead42..174ce752 100644 --- a/setup.py +++ b/setup.py @@ -3,7 +3,7 @@ setup( name='bothub-engine', - version='1.16.0', + version='1.16.1', description='Bothub Engine', packages=find_packages(), install_requires=[