From bab7f5759247e9d4ee1fc351741de7725afc09d5 Mon Sep 17 00:00:00 2001 From: Zlatoslav Desyatnikov Date: Tue, 29 Oct 2019 18:38:39 +0300 Subject: [PATCH 1/4] Get CURL_VERIFY param from config() instead of env() --- config/packager.php | 2 ++ src/FileHandler.php | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/config/packager.php b/config/packager.php index f230c47..9bb7aca 100644 --- a/config/packager.php +++ b/config/packager.php @@ -8,6 +8,8 @@ */ 'skeleton' => 'http://github.com/Jeroen-G/packager-skeleton/archive/master.zip', + 'curl_verify_cert' => env('CURL_VERIFY', true), + /* * You can set defaults for the following placeholders. */ diff --git a/src/FileHandler.php b/src/FileHandler.php index 364048e..27498b6 100644 --- a/src/FileHandler.php +++ b/src/FileHandler.php @@ -109,7 +109,7 @@ public function removeDir($path) */ public function download($zipFile, $source) { - $client = new Client(['verify' => env('CURL_VERIFY', true)]); + $client = new Client(['verify' => config('packager.curl_verify_cert', true)]); $response = $client->get($source); file_put_contents($zipFile, $response->getBody()); From 3d84a1ea184b9b2f84852ab518e005c4b5afa7a5 Mon Sep 17 00:00:00 2001 From: Zlatoslav Desyatnikov Date: Wed, 30 Oct 2019 20:00:38 +0300 Subject: [PATCH 2/4] Update packager.php --- config/packager.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/config/packager.php b/config/packager.php index 9bb7aca..1ef2075 100644 --- a/config/packager.php +++ b/config/packager.php @@ -8,6 +8,12 @@ */ 'skeleton' => 'http://github.com/Jeroen-G/packager-skeleton/archive/master.zip', + /* + * When you run into issues downloading the skeleton, this might be because of + * a file regarding SSL certificates missing on the (Windows) OS. + * This can be solved by setting the verification of the certificate to false. + * Of course this means it will be less secure. + */ 'curl_verify_cert' => env('CURL_VERIFY', true), /* From a6defb644bd95b6c8fae83acc5296295f447387e Mon Sep 17 00:00:00 2001 From: Zlatoslav Desyatnikov Date: Wed, 30 Oct 2019 20:02:25 +0300 Subject: [PATCH 3/4] Update FileHandler.php --- src/FileHandler.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/FileHandler.php b/src/FileHandler.php index 27498b6..72640c2 100644 --- a/src/FileHandler.php +++ b/src/FileHandler.php @@ -109,7 +109,7 @@ public function removeDir($path) */ public function download($zipFile, $source) { - $client = new Client(['verify' => config('packager.curl_verify_cert', true)]); + $client = new Client(['verify' => config('packager.curl_verify_cert')]); $response = $client->get($source); file_put_contents($zipFile, $response->getBody()); From 3901431e5631063e1fd29ad5d0acc7fa59d1b23f Mon Sep 17 00:00:00 2001 From: Zlatoslav Desyatnikov Date: Wed, 30 Oct 2019 20:04:36 +0300 Subject: [PATCH 4/4] Fixed codestyle --- config/packager.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config/packager.php b/config/packager.php index 1ef2075..f359211 100644 --- a/config/packager.php +++ b/config/packager.php @@ -9,8 +9,8 @@ 'skeleton' => 'http://github.com/Jeroen-G/packager-skeleton/archive/master.zip', /* - * When you run into issues downloading the skeleton, this might be because of - * a file regarding SSL certificates missing on the (Windows) OS. + * When you run into issues downloading the skeleton, this might be because of + * a file regarding SSL certificates missing on the (Windows) OS. * This can be solved by setting the verification of the certificate to false. * Of course this means it will be less secure. */