Search Results

Search found 739 results on 30 pages for 'preprocessor directives'.

Page 17/30 | < Previous Page | 13 14 15 16 17 18 19 20 21 22 23 24  | Next Page >

  • Status code in nginx try_files directive

    - by Hamish
    Is it possible to use the current status code as a parameter in try_files? For example, we try to provide a host specific 503 static response, or a server-wide fallback if it wasn't found: error_page 503 @error503; location @error503 { root /path_to_static_root/; try_files /$host/503.html /503.html =503; } There are a number of these directives, so it would be convenient to do something like: error_page 404 @error error_page 500 @error error_page 503 @error location @error { root /path_to_static_root/; try_files /$host/$status.html /$status.html =$status; } But the Variables documentation doesn't list anything that we could use to do this. Is it possible, or is there an alternative way to do this?

    Read the article

  • Force failover a Cisco ASA

    - by user974896
    I have two ASA in a lan state primary\secondary configuration. None of them have "failover active" or "no failover active" in their configuration. Would it be proper to failover in a manner such as: Log into console of primary unit and issue "failover lan state secondary", log into the console of the original secondary unit and issue "failover lan state primary". To fail back simply reverse the process or Log into the console of the primary unit and issue "no failover active", log into the console of the original secondary unit and issue "failover active". To fail back issue "failover active" on the original primary (now secondary) unit, and "no failover active" on the now primary unit. I do not like the second method because it adds configuration directives that were not in place before. Will the first method work?

    Read the article

  • Authentication in Apache2 with mod_dav_svn

    - by Poita_
    I'm having some trouble setting up authentication in Apache2 for a SVN repository that's being served using mod_dav_svn. Here is my Apache config for the directory: <Location /svn> DAV svn SVNParentPath /var/svn/repos AuthType Basic AuthName "Subversion Repository" AuthUserFile /etc/apache2/dev.passwd Require valid-user </Location> I can use svn with the projects under /var/svn/repos, so I know that the DAV is working, but when I do svn updates or commits (or anything), Apache doesn't ask for any authentication... It does the exact same thing whether the Auth directives are there or not. The permissions on the repository directory (and all subdirectories/files) only give permission to www-data (the Apache2 user/group). I have also ensured that all relevant modules are enabled (in particular mod_auth is enabled, as are all mod_dav* modules). Any ideas why svn commands aren't authenticating? Thanks in advance.

    Read the article

  • Setting up Shibboleth to secure part of a website

    - by HorusKol
    I've installed the Shibboleth module for apache on Ubuntu 10.04 using aptitude to install libapache2-mod-shib2 as per https://groups.google.com/group/shibboleth-users/browse_thread/thread/9fca3b2af04d5ca8?pli=1 and enabled the module (I have checked in /etc/apache2/mods-enabled) I then proceeded to secure a directory on the server by placing a .htaccess file with the following directives: AuthType shibboleth ShibRequestSetting requireSession 1 Require valid-user Now - I haven't set up an SSL host yet - and I also haven't set up the IdP - but I would expect that the server would block access to this directory - but I'm getting the content without any problems. I have restarted the apache service and I have no errors in the log files.

    Read the article

  • Allow from referer for HTTP-basic protected SSL apache site

    - by user64204
    I have an apache site protected by HTTP basic authentication. The authentication is working fine. Now I would like to bypass authentication for users that are coming from a particular website by relying on the HTTP Referer header. Here is the configuration: SetEnvIf Referer "^http://.*.example\.org" coming_from_example_org <Directory /var/www/> Options Indexes FollowSymLinks MultiViews AllowOverride None Deny from all Allow from env=coming_from_example_org AuthName "login required" AuthUserFile /opt/http_basic_usernames_and_passwords AuthType Basic Require valid-user Satisfy Any </Directory> This is working fine for HTTP, but failing for HTTPS. My understanding is that in order to inspect the HTTP headers, the SSL handshake must be completed, but apache wants to inspect the <Directory> directives before doing the SSL handshake, even if I place them at the bottom of the configuration file. Q: How could I workaround this issue? PS: I'm not obsessed with the HTTP referer header, I could use other options that would allow users from a known website to bypass authantication.

    Read the article

  • Apache2 + FCGI + PHP5 not creating sockets / pools

    - by CodyRo
    I have a pretty vanilla setup with Apache2, FastCGI setup as DSO and serving PHP through an external CGI script that sets the max children / serves the request to PHP. The issue is FastCGI doesn't appear to be creating the PHP sockets / pooling them so each request calls the php-cgi binary, then dies off .. effectively making the reason I want to use FastCGI moot. The only configuration directives I have are: AddHandler php5-fastcgi .php Action php5-fastcgi /cgi-bin/fcgi.cgi FastCgiIpcDir /usr/local/apache2/fastcgi The dyanmic/ directory is getting created as anticipated, but there are no sockets in there. Permissions are indeed correct. Any help would be greatly appreciated, thanks!

    Read the article

  • How to install latest version of imagick on centos 5.8 64bit using bash

    - by user57221
    How can I download and install latest version of imagick on centos 5.8 64bit using bash for php 5.4. >yum info php Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * base: mirror.ellogroup.com * epel: mirror01.th.ifl.net * extras: mirror.ellogroup.com * updates: mirror.ellogroup.com Installed Packages Name : php Arch : x86_64 Version : 5.4.3 Release : 1.el5.remi Size : 8.8 M Repo : installed Summary : The PHP HTML-embedded scripting language. (PHP: Hypertext Preprocessor) URL : http://www.php.net/ License : PHP Description: PHP is an HTML-embedded scripting language. PHP attempts to make it : easy for developers to write dynamically generated webpages. PHP also : offers built-in database integration for several commercial and : non-commercial database management systems, so writing a : database-enabled webpage with PHP is fairly simple. The most common : use of PHP coding is probably as a replacement for CGI scripts. : : The php package contains the module which adds support for the PHP : language to Apache HTTP Server.

    Read the article

  • A simple way to redirect http://mysite.com to http://mysite.com/mylink with Apache?

    - by Bart Silverstrim
    Just starting to try to get the hang of how all the directives and options work under Apache. I'd like to do a redirect with my one site (only running one site on the server) so that when a request comes in to http://mysite.com the server automatically redirects them to a sub-url of http://mysite.com/mylink. I have tried putting redirects into the file located in /etc/apache2/sites-enabled to rewrite this, but then the top level domain URL complains it isn't redirecting properly. I think what I want is a browser redirect, and thought using RewriteEngine On RewriteRule ^/$ /mylink [L,R] would work, but putting it into an .htaccess file didn't work (it redirected but immediately gave a 500 internal server error.) Putting it into the file in /etc/apache2/sites-enabled gives a configuration error when trying to restart Apache. I know it's something simple...but what am I missing?

    Read the article

  • Using Ruby on share web hosts

    - by Parhum
    We are developing a Wordpress theme and we are going to publish it on themeforest.com. We are using Sass(scss Syntax) as our CSS Preprocessor and we need to compile it on server side. We have two solutions: Use phpsass which is a php script(but it has some bugs) Use Ruby Compiler which most of wordpress plugins use this I noticed that plugins which use Ruby need to have PHP proc_open function enabled on server. My question is what are Pros and Cons of using Ruby compiler on servers? and are most of shared web hosts support Ruby and have PHP proc_open function enabled by default?

    Read the article

  • XAMPP Closes the Connection and won't let me download anything

    - by Miro Markarian
    I want my XAMPP Apache server to host a zip file (The file is around 250mb) but the server closes the connection and won't let me download the file! However webistes are loading correctly and It seems that the problem is with the extension Does xampp/apache have any file extension limit that they won't let me download .zip and .exe files? Also tested with a smaller .exe file , the problem is still present. It just doesn't let me download any file from the server.!!! Here is the file link to check: Test All I get in the error log is this: Fri Sep 07 23:21:31.742625 2012] [authz_core:debug] [pid 3664:tid 396] mod_authz_core.c(808): [client x.x.x.x:23409] AH01628: authorization result: granted (no directives), referer: http://ammiprox.tk/greeneyes2910/

    Read the article

  • Apache htaccess with mod_expires Not Working for certain directories

    - by keyboarddrummer
    I have a Joomla site that I am trying to enable caching using mod_expires. I have the .htaccess in the root of the site and have added the options as found on the page http://www.pactsoftware.nl/tools/joomla-optimization.html Using the PageSpeed extension in Chrome, prior to adding this in my .htaccess, my site scores a 55 (Caching is at the top, and lists a lot of images, CSS, and JS files). After these directives, it scores 70, with caching in the yellow, but still lists some image files (some are two directories deep and the rest are four). I checked for any other .htaccess files in the Joomla root, but none are between those folders and the root. It is almost as if htaccess only works in that one directory, not the subfolders. I have tried putting a .htaccess in each affected subdirectory, but it does not work. Does anyone have any ideas?

    Read the article

  • Add trailing slash when it's missing in nginx

    - by vvanscherpenseel
    I'm running Magento on Nginx using this config: http://www.magentocommerce.com/wiki/1_-_installation_and_configuration/configuring_nginx_for_magento. Now I want to 301 all URLs without trailing slash to their counterpart that includes a trailing slash. For example: /contacts to /contacts/. I've tried virtually all the nginx directives on this I could find, but to no avail. For example, the directive specified in nginx- Rewrite URL with Trailing Slash leads to a redirect to /index.php/. Which directive should I add and where?

    Read the article

  • Apache LocationMatch throws 500 and AddOutputFilterByType does nothing

    - by tackleberry
    I need to add below directives to apache. But I get 500 when I add these lines. <LocationMatch "^/assets/.*$"> Header unset ETag FileETag None # RFC says only cache for 1 year ExpiresActive On ExpiresDefault "access plus 1 year" </LocationMatch> Additionally response is not gzipped when I add: AddOutputFilterByType DEFLATE text/html text/css application/javascript application/x-javascript Apache version is: Server version: Apache/2.2.22 (Unix) App: rails 3.2 app When I checked response&request for gzip problem, I see that browser requested gzip: Accept-Encoding gzip, deflate but response not gzipped.

    Read the article

  • Apache mod_setenvif Server_Addr

    - by user18330
    I have an Apache server in a DMZ, reachaable on the LAN from 192.168.1.1, public 123.456.789.123. I'm trying to get it to require authentication if the inbound hits are coming from the public side. This doesn't seem to work: SetEnvIf SERVER_ADDR 123.456.789.123 local_nic=1 <Location /junk> Order Deny,Allow AuthName "Access required" AuthType Basic AuthUserFile /etc/httpd/conf/htpasswd Require valid-user </Location> What am I doing wrong? Sorry, HTML tags were wiping out my Apache directives.

    Read the article

  • Is it possible to extend a 504 timeout in nginx on a per location basis

    - by codecowboy
    Is it possible to set timeout directives within a location block to prevent nginx returning a 504 from a long running PHP script (PHP-FPM? location /myurlsegment/ { client_body_timeout 1000000; send_timeout 1000000; fastcgi_read_timeout 1000000; } This has no effect when making a request to example.com/myurlsegment. The timeout occurs after approximately 60 seconds. PHP is configured to allow the script to run until completion (set_time_limit(0)) I don't want to set a global timeout for all scripts.

    Read the article

  • Wordpress serving PHP but not CSS or JS

    - by Jason
    I'm trying to set up an Amazon EC2 instance to run a Django app and a WP instance side by side, differing only by the incoming URL. Initially, accessing the site via mysite.com/wordpress worked, but I also needed to catch the incoming requests from a subdomain address blog.mysite.com. To do that, I created a default file in /etc/apache2/sites-enabled and included two virtualhost directives, one of which was <VirtualHost *:80> ServerName www.blog.mysite.com <Directory /var/www/wordpress> Order deny,allow Allow from all </Directory> </VirtualHost> This created some errors with the other virtualhost, so I restored the default 000-default file configuration and restarted. Now, accessing mysite.com/wordpress takes forever, and even then the CSS and JS files are not loading. Iside the Firebug Net tab, I can see the HTML response, but the CSS and JS files are not loading at all. What happened here?

    Read the article

  • Difference between SSLCertificateFile and SSLCertificateChainFile?

    - by chrisjlee
    Normally with a virtual host an ssl is setup with the following directives: Listen 443 SSLCertificateFile /home/web/certs/domain1.public.crt SSLCertificateKeyFile /home/web/certs/domain1.private.key SSLCertificateChainFile /home/web/certs/domain1.intermediate.crt From: For enabling SSL for a single domain on a server with muliple vhosts, will this configuration work? What is the difference between SSLCertificateFile and SSLCertificateChainFile ? The client has purchased a CA key from GoDaddy. It looks like GoDaddy only provides a SSLCertificateFile (.crt file), and a SSLCertificateKeyFile (.key file) and not at SSLCertificateChainFile. Will my ssl still work without a SSLCertificateChainFile path specified ? Also, is there a canonical path where these files should be placed?

    Read the article

  • just another apache to nginx rewrite question

    - by Brandon
    I have the following Apache rewrite directives: RewriteCond %{REQUEST_URI} ^/proxy(/|$) [NC] RewriteCond %{QUERY_STRING} (^|&)uri=(.*?)(&|$) [NC] RewriteRule .* /api/vs1.0/%2 [NC,L] And I'm trying out nginx, so trying to move the rewrites over. I came up with... rewrite ^/proxy(/|$) /api/vs1.0/$2 last; rewrite (^|&)uri=(.*?)(&|$) /api/vs1.0/$2 last; Which is probably grossly incorrect. I'm just a mere web developer, so I was wondering if anyone could lend a hand here. I would be much obliged. I see that I am ignoring the query string specification, but I'm thinking that it shouldn't matter. I only have a vague idea of what the original rewrite is accomplishing, so I haven't much hope here in coming up with something decent, despite reading the relevant documentation for both servers.

    Read the article

  • snmptrap and snmptt - authcommunity not found

    - by sabs6488
    I am trying to configure snmptt to translate the snmp traps received and handle them as passive checks in icinga monitoring server as described here . after doing the changes to the snmptrapd.conf . I am trying to restart the service and I see authcommunity : command not found, traphandle : command not found . my understanding is the authcommunity and traphandle are just configuration directives which will tell snmptrapd about the community string to use and the traphandle script to be called. It would be helpful if someone can help me understand better. Thanks, sabs

    Read the article

  • Case in-sensitivity for Apache httpd Location directive

    - by user57178
    I am working with a solution that requires the usage of mod_proxy_balancer and an application server that both ignores case and mixes different case combinations in URLs found in generated content. The configuration works, however I have now a new requirement that causes problems. I should be able to create a location directive (as per http://httpd.apache.org/docs/current/mod/core.html#location ) and have the URL-path interpret in case insensitive mode. This requirement comes from the need to add authentication directives to the location. As you might guess, users (or the application in question) changing one letter to capital circumvents the protection instantly. The httpd runs on Unix platform so every configuration directive is apparently case sensitive by default. Should the regular expressions in the Location directive work in this case? Could someone please show me an example of such configuration that should work? In case a regular expression can not be forced to work case insensitively, what part of httpd's source code should I go around modifying?

    Read the article

  • Lighttpd domain redirection

    - by HTF
    I would like to redirect domains on HTTP/HTTPS: http://old.com -> https://new.com https://old.com -> https://new.com I have to specify the SSL key/certificate for the old domain but I'm not sure where I have to place these directives: $SERVER["socket"] == ":443" { ssl.engine = "enable" ssl.pemfile = "/etc/pki/tls/private/new.com.pem" ssl.ca-file = "/etc/pki/tls/certs/new.com.crt" } $SERVER["socket"] == ":80" { $HTTP["host"] =~ "old.com|new.com" { url.redirect = ( "^/(.*)" => "https://new.com:443/$1" ) } } I was trying to add the code below but Lighttpd reports configuration errors: $SERVER["socket"] == ":443" { $HTTP["host"] =~ "old.com" { url.redirect = ( "^/(.*)" => "https://new.com:443/$1" ) } ssl.engine = "enable" ssl.pemfile = "/etc/pki/tls/private/old.com.pem" ssl.ca-file = "/etc/pki/tls/certs/old.com.crt" }

    Read the article

  • XAMPP Closes the connection

    - by Miro Markarian
    I want my XAMPP Apache server to host a file (The file is around 250mb) but the server closes the connection and won't let me download the file? Does xampp or apache have any download size limit or something? Tested with a smaller file , the problem is still present. It just doesn't let me download any file from the server.!!! All I get in the error log is this: Fri Sep 07 23:21:31.742625 2012] [authz_core:debug] [pid 3664:tid 396] mod_authz_core.c(808): [client x.x.x.x:23409] AH01628: authorization result: granted (no directives), referer: http://ammiprox.tk/greeneyes2910/

    Read the article

  • Authentication in Apache2 with mod_dav_svn

    - by Poita_
    I'm having some trouble setting up authentication in Apache2 for a SVN repository that's being served using mod_dav_svn. Here is my Apache config for the directory: <Location /svn> DAV svn SVNParentPath /var/svn/repos AuthType Basic AuthName "Subversion Repository" AuthUserFile /etc/apache2/dev.passwd Require valid-user </Location> I can use svn with the projects under /var/svn/repos, so I know that the DAV is working, but when I do svn updates or commits (or anything), Apache doesn't ask for any authentication... It does the exact same thing whether the Auth directives are there or not. The permissions on the repository directory (and all subdirectories/files) only give permission to www-data (the Apache2 user/group). I have also ensured that all relevant modules are enabled (in particular mod_auth is enabled, as are all mod_dav* modules). Any ideas why svn commands aren't authenticating? Thanks in advance.

    Read the article

  • C Language preprocessing doubt

    - by khanna_param
    Hi, There are different kind of macros in C language, nested macro is one of them. Considering a program with the following macro define HYPE(x,y) (SQUR(x)+SQUR(y)) define SQUR(x) (x*x) using this we can successfully complile to get the result. My question:- As we all know the C preprocessor replaces all the occurrence of the identifiers with the replacement-string. Considering the above example i would like to know how many times the C compiler traverses the program to replace the macro with the replacement values. I assume it cannot be done in one go. Thanks.

    Read the article

  • PHP pages are not parsed by Apache on CentOS

    - by infotoknowledge
    I have installed Centos 5.x, Apache 2.2, PHP 5.3 and MySQL 5.5. I also installed phpMyAdmin. I am able to access phpMyAdmin through the browser without any issues. However, when I create a simple index.php with phpinfo() function in the default directory, that page is served without php parsing. As we all know, phpMyAdmin is a php application. This is working fine from the same server but not the simple php page from the doc root directory ??!!!. Of course, I tried moving this page into phpMyAdmin folder and tried accessing it, but no success. Please note that I updated httpd.conf file with appropriate directives based on the php installation guide. docroot - /var/www/html phpMyAdmin folder - /var/www/html/phpMyAdmin Any help is appreciated.

    Read the article

< Previous Page | 13 14 15 16 17 18 19 20 21 22 23 24  | Next Page >