summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPiotr Pawlow <pp@siedziba.pl>2016-04-14 18:02:44 +0200
committerPiotr Pawlow <pp@siedziba.pl>2016-04-14 18:02:44 +0200
commitb7408908e246ab888b84d2f8ae31c99f41cf5508 (patch)
treee72d3a78f164a1445430e519495a4ec181684df4
parenta6a4c734d255793894ca09026867140bbe65d68e (diff)
Add --config optionHEADmaster
-rwxr-xr-xrenew.pl5
1 files changed, 4 insertions, 1 deletions
diff --git a/renew.pl b/renew.pl
index 2cdb8e8..0b25e0e 100755
--- a/renew.pl
+++ b/renew.pl
@@ -6,6 +6,7 @@ use warnings;
use autodie qw(:all);
use Date::Parse;
use LWP::UserAgent;
+use Getopt::Long;
{
our @restart_services_cmd = qw(sudo service httpd graceful);
@@ -15,8 +16,10 @@ use LWP::UserAgent;
our $challenges_dir = 'data/challenges/';
our $days_left_limit = 14;
our $csr_dir = 'data';
+ our $config_file;
- require 'config.pm' if -e 'config.pm';
+ GetOptions("config=s" => \$config_file);
+ require $config_file if defined $config_file;
sub get_intermediate_cert_url {
my $crt_fn = shift;