From 7fe35c5f1c6f35e9b305df367af9297eed879eee Mon Sep 17 00:00:00 2001 From: nemunaire Date: Thu, 8 Dec 2016 12:02:06 +0100 Subject: [PATCH] WIP misc --- admin/static/js/d3.v3.min.js | 1 + admin/static/js/i18n | 1 + frontend/nginx-fic-static.conf | 34 ++++++++++++++++++++++++++++++++++ frontend/static/js/app.js | 1 + frontend/static/robots.txt | 2 ++ 5 files changed, 39 insertions(+) create mode 120000 admin/static/js/d3.v3.min.js create mode 120000 admin/static/js/i18n create mode 100644 frontend/nginx-fic-static.conf create mode 100644 frontend/static/robots.txt diff --git a/admin/static/js/d3.v3.min.js b/admin/static/js/d3.v3.min.js new file mode 120000 index 00000000..d2407e47 --- /dev/null +++ b/admin/static/js/d3.v3.min.js @@ -0,0 +1 @@ +../../../frontend/static/js/d3.v3.min.js \ No newline at end of file diff --git a/admin/static/js/i18n b/admin/static/js/i18n new file mode 120000 index 00000000..dab94408 --- /dev/null +++ b/admin/static/js/i18n @@ -0,0 +1 @@ +../../../frontend/static/js/i18n/ \ No newline at end of file diff --git a/frontend/nginx-fic-static.conf b/frontend/nginx-fic-static.conf new file mode 100644 index 00000000..1d1e2222 --- /dev/null +++ b/frontend/nginx-fic-static.conf @@ -0,0 +1,34 @@ +server { + listen 80 default_server; + listen [::]:80 default_server; + + server_name fic.srs.epita.fr; + + access_log /var/log/nginx/fic2016.access_log main; + error_log /var/log/nginx/fic2016.error_log info; + + root /srv/www/fic2016-static/; + + error_page 403 404 /e404.html; + error_page 413 404 /e413.html; + error_page 500 502 504 /e500.html; + + location /.htaccess { + return 404; + } + location /chbase.sh { + return 404; + } + + location ~ ^/[0-9] { + rewrite ^/.*$ /index.html; + } + + location /edit { + rewrite ^/.*$ /index.html; + } + + location /rank { + rewrite ^/.*$ /index.html; + } +} diff --git a/frontend/static/js/app.js b/frontend/static/js/app.js index bdee2f12..c7aee9ca 100644 --- a/frontend/static/js/app.js +++ b/frontend/static/js/app.js @@ -244,6 +244,7 @@ angular.module("FICApp") $http.get("/my.json").success(function(my) { if ($scope.my.exercices[$rootScope.current_exercice].solved_time != my.exercices[$rootScope.current_exercice].solved_time) { $rootScope.refresh(); + waitMy(); } else { $timeout.cancel($scope.cbd); $scope.cbd = $timeout(checkDiff, 750); diff --git a/frontend/static/robots.txt b/frontend/static/robots.txt new file mode 100644 index 00000000..1f53798b --- /dev/null +++ b/frontend/static/robots.txt @@ -0,0 +1,2 @@ +User-agent: * +Disallow: /