Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove Apache dependency on .htaccess #1

Open
brendanfalkowski opened this issue Mar 5, 2019 · 3 comments
Open

Remove Apache dependency on .htaccess #1

brendanfalkowski opened this issue Mar 5, 2019 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@brendanfalkowski
Copy link
Member

The app can work better out-of-box if index.php is adapted to support Nginx and Apache more easily.

Tasks

  • Check existing projects using Design Docs with Nginx
  • Document necessary config for each system
  • Make code changes to remove need for server config (if possible)
@brendanfalkowski brendanfalkowski added the enhancement New feature or request label Mar 5, 2019
@brendanfalkowski brendanfalkowski self-assigned this Mar 5, 2019
@yoder303
Copy link

I am working on this exact problem, and It's kind of looking like only the rewrite rules need to be adapted.

I'll report back when I get it working.

@yoder303
Copy link

This appears to work.

    location /design {
    index index.php;
        include /etc/nginx/mime.types;
        rewrite ^/([a-z0-9_-]+)/([a-z0-9_-]+)/?$ /design/index.php?p1=$2;
        rewrite ^/([a-z0-9_-]+)/([a-z0-9_-]+)/([a-z0-9_-]+)/?$ /design/index.php?p1=$2&p2=$3;
        rewrite ^/([a-z0-9_-]+)/([a-z0-9_-]+)/([a-z0-9_-]+)/([a-z0-9_-]+)/?$ /design/index.php?p1=$2&p2=$3&p3=$4;
        location ~ \.php {
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_pass unix:/var/run/php/php8.0-fpm.sock;
        fastcgi_index  index.php;
        }
        }

@brendanfalkowski
Copy link
Member Author

Hi @yoder303, thanks for taking the time to test this out. I'm not working on this project currently, but I'll keep the ticket open and it might help someone else out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants