How to undo customized template
I followed the instructions here to create a custom template for a virtual host. It failed because of the missing SSLCertificateFile argument error.
"SSLCertificateFile takes one argument, SSL Server Certificate file (`/path/to/file' - PEM or DER encoded)"
Ok, so the question i have is how do I undo the last step "custom_vhost_template" and remove the "necessary information from the data structure?"
"perl -MYAML::Syck -e \
'my $hr = YAML::Syck::LoadFile($ARGV[0]);$hr->{$ARGV[1]} = $ARGV[2];YAML::Syck::DumpFile($ARGV[0],$hr);' \
/var/cpanel/userdata/$username/$domainname custom_vhost_template_ap2 $path/to/template"
Thanks for your help!
-
Hello :) Could you let us know the exact entries you added to the custom template, excluding any actual domain/IP information? Thank you. 0 -
At first I modified the first line to: It didn't work...so changed it back to the original template file... Still didn't work... Now, I have used this command to "set up the necessary data structure..." "perl -MYAML::Syck -e \ 'my $hr = YAML::Syck::LoadFile($ARGV[0]);$hr->{$ARGV[1]} = $ARGV[2];YAML::Syck::DumpFile($ARGV[0],$hr);' \ /var/cpanel/userdata/$username/$domainname custom_vhost_template_ap2 $path/to/template" But I have no way to undo it...except for using vi to remove the first line in /var/cpanel/userdata/username/subdomain.domain.com custom_vhost_template_ap2: /path/to/custom_templates/username/ssl_vhost.local <--- man handle deleted... Automation... Was that a correct way to deal with that added line? 0 -
Yes, manually editing the file to remove those additions is the correct way to address the issue. Thank you. 0
Please sign in to leave a comment.
Comments
3 comments