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

Servername example.com doesn't exists #5

Open
Mte90 opened this issue Feb 17, 2021 · 5 comments
Open

Servername example.com doesn't exists #5

Mte90 opened this issue Feb 17, 2021 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@Mte90
Copy link

Mte90 commented Feb 17, 2021

On ubuntu or debian that domain in apache doesn't exist but the validate-htaccess command use it: https://github.com/liquidweb/htaccess-validator/blob/develop/bin/validate-htaccess#L43

@Mte90
Copy link
Author

Mte90 commented Feb 18, 2021

I did a gist with some modification so don't require anymore composer and support also stdin with install instructions https://gist.github.com/Mte90/c6568811cd38b60cf05f0e9d8f16bc7a

@stevegrunwell stevegrunwell self-assigned this Feb 23, 2021
@stevegrunwell stevegrunwell added the bug Something isn't working label Feb 23, 2021
@stevegrunwell stevegrunwell added this to the Version 0.1.0 milestone Feb 23, 2021
@stevegrunwell
Copy link
Contributor

@Mte90 Do you happen to have a specific error message you can share? The -C directive explicitly includes a directive before processing the rest of the rule, so the -C "ServerName example.com" is designed to set a default server name in environments where one might not explicitly be set.

#7 also adds Debian support (which I've verified against local Ubuntu VMs), so I'd love your feedback if updating to the version of the script from that PR solves the issues you're seeing.

@Mte90
Copy link
Author

Mte90 commented Feb 24, 2021

Yes, no problem.
I am using it on my Debian machine (I use linux everywhere) and also on my VPS.
So the new feature of my script are based on the pending pull requests and more stuff:

  • Now supports stdin or a file for htaccess rules
  • A parameter to define the domain where will inject on the fly the new rules, default is example.com
  • Remove RewriteBase rule that can create errors from the file passed to the htaccess
  • In case of htaccess error, print it

I can do a pr with that script but I am already using in production as it is on my gist. I integrated also on a test suites for a tool that generate htaccess stuff we are developing for our customers.

@stevegrunwell
Copy link
Contributor

I'll dig into the gist further and reconcile those changes with what's already been done in #6 and #7.

I integrated also on a test suites for a tool that generate htaccess stuff we are developing for our customers.

How did you guess why this package was developed? 😉

@Mte90
Copy link
Author

Mte90 commented Mar 2, 2021

Ahahah yes, we were looking for the same thing.

@stevegrunwell stevegrunwell removed this from the Version 0.1.0 milestone Mar 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants