Configure Nginx to run PhalconPHP on a subfolderWhy nginx internal redirect is not happeningHow do I get PHP 5.3.3 working with Nginx on CentOS 5.5?Blank Page: wordpress on nginx+php-fpmphpmyadmin having problems on nginx and php-fpm on RHEL 6nginx php5-fpm path_info urls and root locationPHP app breaks on Nginx, but works on ApacheNGINX don't parse .php5 as .phpLaravel 4.1 on nginx routes error 404CodeIgniter nginx rewrite rules for i8ln URL'sHow to configure nginx to serve one site from two different document root and using different php depending on URLlimit_req_zone for the whole PHP
Do we or do we not observe (measure) superpositions all the time?
Did Chinese school textbook maps (c. 1951) "depict China as stretching even into the central Asian republics"?
Three column layout
How do accents of a whole town drift?
Is there any set of 2-6 notes that doesn't have a chord name?
Analog is Obtuse!
Can a single server be associated with multiple domains?
Do sudoku answers always have a single minimal clue set?
Does ultrasonic bath cleaning damage laboratory volumetric glassware calibration?
Compute unstable integral with high precision
Should I include salary information on my CV?
Alphabet completion rate
Do I have to roll to maintain concentration if a target other than me who is affected by my concentration spell takes damage?
How well known and how commonly used was Huffman coding in 1979?
Quacks of Quedlingburg Crow Skull Set 2 Keep Drawing
When to apply Lorentz transformations and laws of time dilations and length contractions: explanations
Transitive verb + interrupter + object?
Why is Madam Hooch not a professor?
How can I check type T is among parameter pack Ts... in C++?
I played my first (rapid) tournament recently and I wanted to calculate my ELO
Can you sign using a digital signature itself?
How can I convince my reader that I will not use a certain trope?
Polish letters in ASME English template
How would a order of Monks that renounce their names communicate effectively?
Configure Nginx to run PhalconPHP on a subfolder
Why nginx internal redirect is not happeningHow do I get PHP 5.3.3 working with Nginx on CentOS 5.5?Blank Page: wordpress on nginx+php-fpmphpmyadmin having problems on nginx and php-fpm on RHEL 6nginx php5-fpm path_info urls and root locationPHP app breaks on Nginx, but works on ApacheNGINX don't parse .php5 as .phpLaravel 4.1 on nginx routes error 404CodeIgniter nginx rewrite rules for i8ln URL'sHow to configure nginx to serve one site from two different document root and using different php depending on URLlimit_req_zone for the whole PHP
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
I want to run a PhalconPHP application on a subfolder like this http://stg.example.org/simon/apps/phalconapp/
A snippet of my Nginx configuration is as below...
location ^~ /simon/apps/phalconapp
root /var/www/stg.example.org/simon/apps/phalconapp/public;
index index.php index.html index.htm;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_split_path_info ^(.+.php)(/.+)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
location @rewrite
rewrite ^/(.*)$ /index.php?_url=/$1;
I however, get a file not found error when trying to access the application. What could I be doing wrong?
=========
updated configuration
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp/public;
index index.php index.html index.htm;
try_files $uri $uri/ @rewrite;
if (!-e $request_filename)
rewrite ^ /simon/apps/phalconapp/public/index.php?_url=/$1 last;
location ~ .php$
if (!-f $request_filename)
rewrite ^ /simon/apps/phalconapp/public/index.php?_url=/$1 last;
fastcgi_pass 127.0.0.1:9000; #set port for php-fpm to listen on
fastcgi_index index.php;
try_files $uri =404;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
fastcgi_split_path_info ^(.+.php)(/.+)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
location @rewrite
rewrite ^/(.*)$ /simon/apps/phalconapp/public/index.php?_url=/$1;
======= Almost working configuration 2
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp;
index index.php index.html;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $request_filename;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
location @rewrite
rewrite ^/(.*)$ /simon/apps/phalconapp/public/index.php?_url=/$1;
nginx php php-fpm
add a comment |
I want to run a PhalconPHP application on a subfolder like this http://stg.example.org/simon/apps/phalconapp/
A snippet of my Nginx configuration is as below...
location ^~ /simon/apps/phalconapp
root /var/www/stg.example.org/simon/apps/phalconapp/public;
index index.php index.html index.htm;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_split_path_info ^(.+.php)(/.+)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
location @rewrite
rewrite ^/(.*)$ /index.php?_url=/$1;
I however, get a file not found error when trying to access the application. What could I be doing wrong?
=========
updated configuration
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp/public;
index index.php index.html index.htm;
try_files $uri $uri/ @rewrite;
if (!-e $request_filename)
rewrite ^ /simon/apps/phalconapp/public/index.php?_url=/$1 last;
location ~ .php$
if (!-f $request_filename)
rewrite ^ /simon/apps/phalconapp/public/index.php?_url=/$1 last;
fastcgi_pass 127.0.0.1:9000; #set port for php-fpm to listen on
fastcgi_index index.php;
try_files $uri =404;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
fastcgi_split_path_info ^(.+.php)(/.+)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
location @rewrite
rewrite ^/(.*)$ /simon/apps/phalconapp/public/index.php?_url=/$1;
======= Almost working configuration 2
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp;
index index.php index.html;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $request_filename;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
location @rewrite
rewrite ^/(.*)$ /simon/apps/phalconapp/public/index.php?_url=/$1;
nginx php php-fpm
Nginx is looking for files at/var/www/stg.example.org/simon/apps/phalconapp/public/simon/apps/phalconapp, so you need to usealiasinstead ofroot. See this answer. Your@rewriteblock is also incorrect, the correct URI should be:/simon/apps/phalconapp/index.phpand not/index.php.
– Richard Smith
Jun 10 at 7:34
Thanks @RichardSmith. I have updated configuration as shown above but the problem persists:-
– Obirieni Simeo
Jun 10 at 8:12
You have left thetry_filesstatements in. You don't needtry_filesand theifblocks, they are both doing the same job. Usefastcgi_param SCRIPT_FILENAME $request_filename;when usingalias.
– Richard Smith
Jun 10 at 8:36
I managed to get it to work using configuration 2, above. However, I am unable to get Phalcon to interpret the URI correctly. It should interpret it asstg.example.org/simon/apps/phalconapp/<module>/<controller>/<action>, but is instead interpretingsimonas the module,appsas controller etc. Any clues on how to make Phalcon understand that/simon/apps/phalconapp/is just the base uri?
– Obirieni Simeo
Jun 10 at 13:39
add a comment |
I want to run a PhalconPHP application on a subfolder like this http://stg.example.org/simon/apps/phalconapp/
A snippet of my Nginx configuration is as below...
location ^~ /simon/apps/phalconapp
root /var/www/stg.example.org/simon/apps/phalconapp/public;
index index.php index.html index.htm;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_split_path_info ^(.+.php)(/.+)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
location @rewrite
rewrite ^/(.*)$ /index.php?_url=/$1;
I however, get a file not found error when trying to access the application. What could I be doing wrong?
=========
updated configuration
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp/public;
index index.php index.html index.htm;
try_files $uri $uri/ @rewrite;
if (!-e $request_filename)
rewrite ^ /simon/apps/phalconapp/public/index.php?_url=/$1 last;
location ~ .php$
if (!-f $request_filename)
rewrite ^ /simon/apps/phalconapp/public/index.php?_url=/$1 last;
fastcgi_pass 127.0.0.1:9000; #set port for php-fpm to listen on
fastcgi_index index.php;
try_files $uri =404;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
fastcgi_split_path_info ^(.+.php)(/.+)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
location @rewrite
rewrite ^/(.*)$ /simon/apps/phalconapp/public/index.php?_url=/$1;
======= Almost working configuration 2
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp;
index index.php index.html;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $request_filename;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
location @rewrite
rewrite ^/(.*)$ /simon/apps/phalconapp/public/index.php?_url=/$1;
nginx php php-fpm
I want to run a PhalconPHP application on a subfolder like this http://stg.example.org/simon/apps/phalconapp/
A snippet of my Nginx configuration is as below...
location ^~ /simon/apps/phalconapp
root /var/www/stg.example.org/simon/apps/phalconapp/public;
index index.php index.html index.htm;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_split_path_info ^(.+.php)(/.+)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
location @rewrite
rewrite ^/(.*)$ /index.php?_url=/$1;
I however, get a file not found error when trying to access the application. What could I be doing wrong?
=========
updated configuration
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp/public;
index index.php index.html index.htm;
try_files $uri $uri/ @rewrite;
if (!-e $request_filename)
rewrite ^ /simon/apps/phalconapp/public/index.php?_url=/$1 last;
location ~ .php$
if (!-f $request_filename)
rewrite ^ /simon/apps/phalconapp/public/index.php?_url=/$1 last;
fastcgi_pass 127.0.0.1:9000; #set port for php-fpm to listen on
fastcgi_index index.php;
try_files $uri =404;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
fastcgi_split_path_info ^(.+.php)(/.+)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
location @rewrite
rewrite ^/(.*)$ /simon/apps/phalconapp/public/index.php?_url=/$1;
======= Almost working configuration 2
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp;
index index.php index.html;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $request_filename;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
location @rewrite
rewrite ^/(.*)$ /simon/apps/phalconapp/public/index.php?_url=/$1;
nginx php php-fpm
nginx php php-fpm
edited Jun 10 at 13:44
Obirieni Simeo
asked Jun 10 at 7:14
Obirieni SimeoObirieni Simeo
63 bronze badges
63 bronze badges
Nginx is looking for files at/var/www/stg.example.org/simon/apps/phalconapp/public/simon/apps/phalconapp, so you need to usealiasinstead ofroot. See this answer. Your@rewriteblock is also incorrect, the correct URI should be:/simon/apps/phalconapp/index.phpand not/index.php.
– Richard Smith
Jun 10 at 7:34
Thanks @RichardSmith. I have updated configuration as shown above but the problem persists:-
– Obirieni Simeo
Jun 10 at 8:12
You have left thetry_filesstatements in. You don't needtry_filesand theifblocks, they are both doing the same job. Usefastcgi_param SCRIPT_FILENAME $request_filename;when usingalias.
– Richard Smith
Jun 10 at 8:36
I managed to get it to work using configuration 2, above. However, I am unable to get Phalcon to interpret the URI correctly. It should interpret it asstg.example.org/simon/apps/phalconapp/<module>/<controller>/<action>, but is instead interpretingsimonas the module,appsas controller etc. Any clues on how to make Phalcon understand that/simon/apps/phalconapp/is just the base uri?
– Obirieni Simeo
Jun 10 at 13:39
add a comment |
Nginx is looking for files at/var/www/stg.example.org/simon/apps/phalconapp/public/simon/apps/phalconapp, so you need to usealiasinstead ofroot. See this answer. Your@rewriteblock is also incorrect, the correct URI should be:/simon/apps/phalconapp/index.phpand not/index.php.
– Richard Smith
Jun 10 at 7:34
Thanks @RichardSmith. I have updated configuration as shown above but the problem persists:-
– Obirieni Simeo
Jun 10 at 8:12
You have left thetry_filesstatements in. You don't needtry_filesand theifblocks, they are both doing the same job. Usefastcgi_param SCRIPT_FILENAME $request_filename;when usingalias.
– Richard Smith
Jun 10 at 8:36
I managed to get it to work using configuration 2, above. However, I am unable to get Phalcon to interpret the URI correctly. It should interpret it asstg.example.org/simon/apps/phalconapp/<module>/<controller>/<action>, but is instead interpretingsimonas the module,appsas controller etc. Any clues on how to make Phalcon understand that/simon/apps/phalconapp/is just the base uri?
– Obirieni Simeo
Jun 10 at 13:39
Nginx is looking for files at
/var/www/stg.example.org/simon/apps/phalconapp/public/simon/apps/phalconapp, so you need to use alias instead of root. See this answer. Your @rewrite block is also incorrect, the correct URI should be: /simon/apps/phalconapp/index.php and not /index.php.– Richard Smith
Jun 10 at 7:34
Nginx is looking for files at
/var/www/stg.example.org/simon/apps/phalconapp/public/simon/apps/phalconapp, so you need to use alias instead of root. See this answer. Your @rewrite block is also incorrect, the correct URI should be: /simon/apps/phalconapp/index.php and not /index.php.– Richard Smith
Jun 10 at 7:34
Thanks @RichardSmith. I have updated configuration as shown above but the problem persists:-
– Obirieni Simeo
Jun 10 at 8:12
Thanks @RichardSmith. I have updated configuration as shown above but the problem persists:-
– Obirieni Simeo
Jun 10 at 8:12
You have left the
try_files statements in. You don't need try_files and the if blocks, they are both doing the same job. Use fastcgi_param SCRIPT_FILENAME $request_filename; when using alias.– Richard Smith
Jun 10 at 8:36
You have left the
try_files statements in. You don't need try_files and the if blocks, they are both doing the same job. Use fastcgi_param SCRIPT_FILENAME $request_filename; when using alias.– Richard Smith
Jun 10 at 8:36
I managed to get it to work using configuration 2, above. However, I am unable to get Phalcon to interpret the URI correctly. It should interpret it as
stg.example.org/simon/apps/phalconapp/<module>/<controller>/<action> , but is instead interpreting simon as the module, apps as controller etc. Any clues on how to make Phalcon understand that /simon/apps/phalconapp/ is just the base uri?– Obirieni Simeo
Jun 10 at 13:39
I managed to get it to work using configuration 2, above. However, I am unable to get Phalcon to interpret the URI correctly. It should interpret it as
stg.example.org/simon/apps/phalconapp/<module>/<controller>/<action> , but is instead interpreting simon as the module, apps as controller etc. Any clues on how to make Phalcon understand that /simon/apps/phalconapp/ is just the base uri?– Obirieni Simeo
Jun 10 at 13:39
add a comment |
1 Answer
1
active
oldest
votes
This configuration has worked for me. I will however appreciate if this answer can be improved by someone who is more knowledgeable with Nginx configurations.
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp;
index index.php index.html;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $request_filename;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
location @rewrite
rewrite ^/simon/apps/phalconapp(.*)$ /simon/apps/phalconapp/public/index.php?_url=$1 ;
add a comment |
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "2"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f970777%2fconfigure-nginx-to-run-phalconphp-on-a-subfolder%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
This configuration has worked for me. I will however appreciate if this answer can be improved by someone who is more knowledgeable with Nginx configurations.
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp;
index index.php index.html;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $request_filename;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
location @rewrite
rewrite ^/simon/apps/phalconapp(.*)$ /simon/apps/phalconapp/public/index.php?_url=$1 ;
add a comment |
This configuration has worked for me. I will however appreciate if this answer can be improved by someone who is more knowledgeable with Nginx configurations.
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp;
index index.php index.html;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $request_filename;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
location @rewrite
rewrite ^/simon/apps/phalconapp(.*)$ /simon/apps/phalconapp/public/index.php?_url=$1 ;
add a comment |
This configuration has worked for me. I will however appreciate if this answer can be improved by someone who is more knowledgeable with Nginx configurations.
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp;
index index.php index.html;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $request_filename;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
location @rewrite
rewrite ^/simon/apps/phalconapp(.*)$ /simon/apps/phalconapp/public/index.php?_url=$1 ;
This configuration has worked for me. I will however appreciate if this answer can be improved by someone who is more knowledgeable with Nginx configurations.
location ^~ /simon/apps/phalconapp
alias /var/www/stg.example.org/simon/apps/phalconapp;
index index.php index.html;
try_files $uri $uri/ @rewrite;
location ~ .php$
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $request_filename;
include fastcgi_params;
include /etc/nginx/fastcgi_params;
location @rewrite
rewrite ^/simon/apps/phalconapp(.*)$ /simon/apps/phalconapp/public/index.php?_url=$1 ;
answered Jun 10 at 16:17
Obirieni SimeoObirieni Simeo
63 bronze badges
63 bronze badges
add a comment |
add a comment |
Thanks for contributing an answer to Server Fault!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f970777%2fconfigure-nginx-to-run-phalconphp-on-a-subfolder%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Nginx is looking for files at
/var/www/stg.example.org/simon/apps/phalconapp/public/simon/apps/phalconapp, so you need to usealiasinstead ofroot. See this answer. Your@rewriteblock is also incorrect, the correct URI should be:/simon/apps/phalconapp/index.phpand not/index.php.– Richard Smith
Jun 10 at 7:34
Thanks @RichardSmith. I have updated configuration as shown above but the problem persists:-
– Obirieni Simeo
Jun 10 at 8:12
You have left the
try_filesstatements in. You don't needtry_filesand theifblocks, they are both doing the same job. Usefastcgi_param SCRIPT_FILENAME $request_filename;when usingalias.– Richard Smith
Jun 10 at 8:36
I managed to get it to work using configuration 2, above. However, I am unable to get Phalcon to interpret the URI correctly. It should interpret it as
stg.example.org/simon/apps/phalconapp/<module>/<controller>/<action>, but is instead interpretingsimonas the module,appsas controller etc. Any clues on how to make Phalcon understand that/simon/apps/phalconapp/is just the base uri?– Obirieni Simeo
Jun 10 at 13:39