Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I'm posting here because searching for several hours didn't solve my problem, I have some strange things happening with DirectAdmin on one particular domain.

I'm using a custom virtual_host2_sub.conf file with the following contents:

|?CGI=ScriptAlias /cgi-bin/ `HOME`/domains/`DOMAIN`/public_html/cgi-bin/|
|?DOCROOT=`HOME`/domains/`SUB`.`DOMAIN`|
|?OPEN_BASEDIR_PATH=`HOME`/:/tmp:/var/tmp:/usr/local/lib/php/|
<VirtualHost |IP|:|PORT_80| |MULTI_IP|>
|CUSTOM|
        SSLEngine off
        SSLCertificateFile |CERT|
        SSLCertificateKeyFile |KEY|
        |CAROOT|

        ServerName |SUB|.|DOMAIN|
        ServerAlias www.|SUB|.|DOMAIN| |SUB|.|DOMAIN| |SERVER_ALIASES|
        ServerAdmin |ADMIN|
        DocumentRoot |DOCROOT|
        |CGI|

        |USECANONICALNAME|

        SuexecUserGroup |USER| |GROUP|
        CustomLog /var/log/httpd/domains/|DOMAIN|.|SUB|.bytes bytes
        CustomLog /var/log/httpd/domains/|DOMAIN|.|SUB|.log combined
        ErrorLog /var/log/httpd/domains/|DOMAIN|.|SUB|.error.log

        <Directory |DOCROOT|>
                Options +Includes -Indexes
                |*if CLI="1"|
                    php_admin_flag engine |PHP|
                    <IfModule !mod_php6.c>
                            php_admin_flag safe_mode |SAFE_MODE|
                    </IfModule>
                    php_admin_value sendmail_path '/usr/sbin/sendmail -t -i -f |USER|@|DOMAIN|'
                |*endif|
                |*if OPEN_BASEDIR="ON"|
                    php_admin_value open_basedir |OPEN_BASEDIR_PATH|
                |*endif|
                |*if SUPHP="1"|
                    suPHP_Engine |PHP|
                    suPHP_UserGroup |USER| |GROUP|
                |*endif|
        </Directory>
|HANDLERS|
|MIMETYPES|

</VirtualHost>

Now, the problem is strange - i keep having problems with the subdomain poiting to https all the time. I've installed a wordpress installation which only gives me plain HTML because all the links in the source are leading to https://..

I'm sure it's because of this custom file because I've had the same problems with another domain in the past, as this issue returned and I couldn't find a complete solution yet I wanted to ask here with the experts to review my file and hope someone could possibly tell me what could be wrong.

I think I may have copied the secure_sub instead of the sub file but it's been so long I have no idea anymore.

Could the problem be in the SSLEngine?

share|improve this question

1 Answer 1

If what you're refering to is that your Wordpress keeps getting redirected to https://, that might be because Wordpress defines your blog URL during the installation. If you do the installation process using an HTTPS URL, Wordpress will always redirect you to https://yourblog.com. If that's the case, you might want to check WP's "Changing The Site URL" help.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.