@vetalmatitskiy
testing engineer

В чем может быть проблема с конфиругацией сайта на Linux?

Доброго дня, уважаемые гуру веба. пытаюсь локально запустить рабочую версию проекта. Бекендер в проекте все разрабатывает и тестит строго на винде и ничего кроме пользования openserver не знает, я же использую больше Ubuntu и при попытке запустить сайт с теми же версиями апача, mysql,php показывается лишь список файлов в папке,
652d1180b8844721bd398ee6cc22d08b.png
хотя под виндой все нормально подымается. пишу на проекте фронтенд и апачем почти не пользуюсь. есть ли какие-то способы понять в чем проблема с конфигами?
файл .htaccess имеет вид
AddDefaultCharset utf-8
AddCharset utf-8 *
<Files .htaccess>
	order allow,deny
	deny from all
</Files>
<Files *.ini>  
    Order deny,allow
    Deny from all
</Files>
#OLD -- AddOutputFilterByType DEFLATE text/plain text/css text/javascript application/javascript 
<IfModule mod_deflate.c>
    # Выставляем заголовок Content-Encoding: gzip.
    AddEncoding gzip .gz
    
    # Для favicon.ico
    AddOutputFilterByType DEFLATE image/x-icon
    # Для CSS-файлов.
    AddOutputFilterByType DEFLATE text/css
    # Для JavaScript-файлов.
    AddOutputFilterByType DEFLATE text/javascript
    AddOutputFilterByType DEFLATE application/x-javascript
    AddOutputFilterByType DEFLATE application/javascript
    AddOutputFilterByType DEFLATE application/json
    # Для остальных типов файлов.
    AddOutputFilterByType DEFLATE text/plain
    AddOutputFilterByType DEFLATE text/x-component
    AddOutputFilterByType DEFLATE text/xml
    AddOutputFilterByType DEFLATE application/xml
    AddOutputFilterByType DEFLATE application/rss+xml
    AddOutputFilterByType DEFLATE application/atom+xml
    AddOutputFilterByType DEFLATE font/truetype
    AddOutputFilterByType DEFLATE font/opentype
    AddOutputFilterByType DEFLATE application/vnd.ms-fontobject
    AddOutputFilterByType DEFLATE image/svg+xml
    
    # Отключаем сжатие для тех браузеров, у которых проблемы
    # с его распознаванием.
    BrowserMatch "MSIE [456]" no_gzip dont-vary
    BrowserMatch "SV1;" !no_gzip !dont-vary
    BrowserMatch "Opera" !no_gzip !dont-vary
    BrowserMatch "Firefox/[0-3]\." gzip-only-text/html
    BrowserMatch "Firefox/3\.[1-9]" !gzip-only-text/html
    BrowserMatch "Chrome/2" gzip-only-text/html
    BrowserMatch "Safari" gzip-only-text/html
    BrowserMatch "Konqueror" gzip-only-text/html
</IfModule>
<IfModule dir_module>
    DirectoryIndex _fianta.php index.php index.html
</IfModule>
<IfModule mod_expires.c>
	FileETag MTime Size
	ExpiresActive on
	ExpiresDefault                                  "access plus 1 month"
	ExpiresByType text/cache-manifest               "access plus 0 seconds"
	ExpiresByType text/html                         "access plus 0 seconds"
	ExpiresByType text/xml                          "access plus 0 seconds"
	ExpiresByType application/xml                   "access plus 0 seconds"
	ExpiresByType application/json                  "access plus 0 seconds"
	ExpiresByType application/rss+xml       		"access plus 1 month"
	ExpiresByType image/x-icon              		"access plus 1 week" 
	ExpiresByType image/gif                 		"access plus 1 year"
	ExpiresByType image/png                 		"access plus 1 year"
	ExpiresByType image/jpg                 		"access plus 1 year"
	ExpiresByType image/jpeg                		"access plus 1 year"
	ExpiresByType video/ogg                 		"access plus 1 year"
	ExpiresByType audio/ogg                 		"access plus 1 year"
	ExpiresByType audio/mp3                 		"access plus 1 year"
	ExpiresByType video/mp4                 		"access plus 1 year"
	ExpiresByType video/x-flv 						"access plus 1 years"
	ExpiresByType video/webm                		"access plus 1 year"
	ExpiresByType text/x-component          		"access plus 1 month"
	ExpiresByType font/truetype             		"access plus 1 year"
	ExpiresByType font/opentype             		"access plus 1 year"
	ExpiresByType application/x-font-woff   		"access plus 1 year"
	ExpiresByType image/svg+xml             		"access plus 1 month"
	ExpiresByType application/vnd.ms-fontobject 	"access plus 1 year"
	ExpiresByType text/css                  		"modification plus 3 months"
	ExpiresByType application/javascript    		"modification plus 3 months"
	ExpiresByType application/x-javascript  		"modification plus 3 months"
	ExpiresByType text/javascript           		"modification plus 3 months"
</IfModule>
<IfModule mod_headers.c>
	Header append Cache-Control 					"public"
</IfModule>
# Заперещаем открытие сайта в iframe, на стороннем ресурсе. Тем самым предотвращаем clickjacking.
<IfModule mod_headers.c>
    Header set X-Frame-Options "SAMEORIGIN"
    <FilesMatch "\.(appcache|atom|crx|css|cur|eot|f4[abpv]|flv|gif|htc|ico|jpe?g|js|json(ld)?|m4[av]|manifest|map|mp4|oex|og[agv]|opus|otf|pdf|png|rdf|rss|safariextz|svgz?|swf|tt[cf]|vcf|vtt|webapp|web[mp]|woff|xml|xpi)$">
        Header unset X-Frame-Options
    </FilesMatch>
</IfModule>
# Запрещаем IE автоматически определять тип документа. 
# Т.к. это потенциально может привести к проблемам с безопасностью.
<IfModule mod_headers.c>
    Header set X-Content-Type-Options "nosniff"
</IfModule>

# Отключаем вывод информации о сервере.
ServerSignature Off
#AddHandler application/x-httpd-php55  .php55 .php
#php_flag expose_php Off

#SetEnv TZ Europe/Kiev
php_value date.timezone Europe/Kiev

php_value upload_max_filesize 20M
php_value post_max_size 30M

Options -Indexes
ErrorDocument 403 /_404.php
ErrorDocument 404 /_404.php

RewriteEngine on
RewriteBase /

#FIANTA ENTRY
<IfModule mod_rewrite.c>
    RewriteCond %{HTTPS} !=on
    RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC]
    RewriteRule ^(.*)$ http://%1/$1 [R=301,L]
</IfModule>
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d

RewriteRule ^(.*).html$ _fianta.php?a=$1 [L,QSA]
  • Вопрос задан
  • 374 просмотра
Пригласить эксперта
Ответы на вопрос 2
e_svirsky
@e_svirsky
Web Developer
А что если напрямую запустить _fianta.php?
site.dev/_fianta.php

Если заработает, значит не работает DirectoryIndex директива.
Ответ написан
Комментировать
#AddHandler application/x-httpd-php55 .php55 .php
очень давно уже htaccess не видел в глаза,смущает строчка, вроде закомментировано, а раскомментированной похожей не вижу.
Апаче откуда знает, что исполнять как php?
Ответ написан
Комментировать
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Войти через центр авторизации
Похожие вопросы