apache2

Optionally pass REMOTE_USER to application

杀马特。学长 韩版系。学妹 提交于 2020-01-15 03:24:09
问题 In our company we have an apache server running a django application (through wsgi) and some legacy php applications. To have some sort of single sign on we decided to use mod_auth_form and wsgi as the AuthFormProvider. In django itself we enabled the RemoteUserBackend and all works fine. The legacy php applications are also protected via mod_auth_form and wsgi. The problem is that there are some locations which should be accessible by authenticated and anonymous users where authenticated

Must-revalidate headers of this request wrong?

好久不见. 提交于 2020-01-14 18:55:10
问题 I noticed that chrome cached a video file. I replaced it with another one on the server and chrome kept serving the old one from cache (using JW flash player 5) The headers of the request look like this: joe@joe-desktop:~$ wget -O - -S --spider http://www.2xfun.de/files_geheimhihi14/20759.mp4 Spider mode enabled. Check if remote file exists. --2011-05-15 22:40:56-- http://www.2xfun.de/files_geheimhihi14/20759.mp4 Resolving www.2xfun.de... 213.239.214.112 Connecting to www.2xfun.de|213.239.214

Django Response always Chunked with text/html cannot set Content-Length

梦想与她 提交于 2020-01-14 14:26:27
问题 In my Django Application's views.py , I return an HttpResponse object after attempting to set the following HTTP Header fields: # Create a Response Object with the content to return response = HttpResponse("%s"%(output_display),mimetype='text/html') response['Cache-Control'] = 'must-revalidate, max-age=20' response['Vary'] = 'Accept-Encoding' response['Transfer-Encoding'] = 'gzip' #response['Content-Encoding'] = 'gzip' response['Connection'] = 'close' #response['Content-Type'] = 'text/html'

Django Response always Chunked with text/html cannot set Content-Length

亡梦爱人 提交于 2020-01-14 14:26:09
问题 In my Django Application's views.py , I return an HttpResponse object after attempting to set the following HTTP Header fields: # Create a Response Object with the content to return response = HttpResponse("%s"%(output_display),mimetype='text/html') response['Cache-Control'] = 'must-revalidate, max-age=20' response['Vary'] = 'Accept-Encoding' response['Transfer-Encoding'] = 'gzip' #response['Content-Encoding'] = 'gzip' response['Connection'] = 'close' #response['Content-Type'] = 'text/html'

Django Response always Chunked with text/html cannot set Content-Length

|▌冷眼眸甩不掉的悲伤 提交于 2020-01-14 14:26:08
问题 In my Django Application's views.py , I return an HttpResponse object after attempting to set the following HTTP Header fields: # Create a Response Object with the content to return response = HttpResponse("%s"%(output_display),mimetype='text/html') response['Cache-Control'] = 'must-revalidate, max-age=20' response['Vary'] = 'Accept-Encoding' response['Transfer-Encoding'] = 'gzip' #response['Content-Encoding'] = 'gzip' response['Connection'] = 'close' #response['Content-Type'] = 'text/html'

Access-Control-Allow-Origin headers not working

早过忘川 提交于 2020-01-14 12:49:26
问题 Even though I've added this in my .htaccess file: Header add Access-Control-Allow-Origin "*" And this in my apache config: (Inside a section AND outside) <Files ~ "\.(gif|jpe?g|png|js|json|xml)$"> Header set Access-Control-Allow-Origin "*" </Files> It still does not work! When I get the DIRECTORY it does give me the wanted header, but as soon as I download a specific file the header is nowhere to be found! How hard can it be? 回答1: try <FilesMatch "\.(gif|jpe?g|png|js|json|xml)$"> <IfModule

PHP 7.2: no additional .ini files parsed

﹥>﹥吖頭↗ 提交于 2020-01-14 11:53:33
问题 I have an ubuntu server (16.04.4 LTS) with apache2 running php7.0 (Apache 2.0 Handler) and php7.2 (FPM/FastCGI). PHP7.2 works fine, except that there are no extensions loaded - like json or anything else. See my phpinfo(): System Linux srvindkdif 4.4.0-62-generic #83-Ubuntu SMP Wed Jan 18 14:10:15 UTC 2017 x86_64 Build Date Jun 22 2018 08:44:50 Server API FPM/FastCGI Virtual Directory Support disabled Configuration File (php.ini) Path /etc/php/7.2/fpm Loaded Configuration File /etc/php/7.2

The requested URL /frontend/ru/site/login/ was not found on this server

做~自己de王妃 提交于 2020-01-14 06:18:47
问题 I have a problem, that my project working very nice on windows(on apache server ),then I moved my project to ubuntu 12.04 (apache2 server), but my project do not working. apache2 php 5.3.10 mysql 5.5.29-ubuntu0.12.04.2 on firebug: <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> <html><head> <title>404 Not Found</title> </head><body> <h1>Not Found</h1> <p>The requested URL /frontend/ru/site/login/ was not found on this server.</p> <hr> <address>Apache/2.2.22 (Ubuntu) Server at test.local

Apache PHP5-FPM connection reset by peer

三世轮回 提交于 2020-01-13 12:06:31
问题 Things like this keep popping up in my apache logs. How can I go about debugging this and/or preventing this in the future: (104)Connection reset by peer: FastCGI: comm with server "/var/www/php5.external" aborted: read failed FastCGI: incomplete headers (0 bytes) received from server "/var/www/php5.external", (4)Interrupted system call: FastCGI: comm with server "/var/www/php5.external" aborted: select() failed 回答1: In relation to your "select() failed" error and possibly the others, check

Apache PHP5-FPM connection reset by peer

◇◆丶佛笑我妖孽 提交于 2020-01-13 12:04:27
问题 Things like this keep popping up in my apache logs. How can I go about debugging this and/or preventing this in the future: (104)Connection reset by peer: FastCGI: comm with server "/var/www/php5.external" aborted: read failed FastCGI: incomplete headers (0 bytes) received from server "/var/www/php5.external", (4)Interrupted system call: FastCGI: comm with server "/var/www/php5.external" aborted: select() failed 回答1: In relation to your "select() failed" error and possibly the others, check