From e546da136e507bb111aa5196b52825aada41a8c4 Mon Sep 17 00:00:00 2001 From: digitalextremist // Date: Fri, 13 Dec 2019 11:15:48 -0800 Subject: [PATCH] fix constant defining --- CHANGES.md | 2 +- shard.yml | 2 +- src/artillery/initialize.cr | 7 +++---- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 57f8437..35dbc0e 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,4 +1,4 @@ -# v201912131050-4Kg1 0.0.1.23 +# v201912131050-4Kg1 0.0.1.24 * Allow override of configuration file name * Pass content-type as `request.format` and pass JSON body as `request.data` diff --git a/shard.yml b/shard.yml index 76bcb7c..05bba95 100644 --- a/shard.yml +++ b/shard.yml @@ -1,5 +1,5 @@ name: artillery -version: 0.0.1.23 +version: 0.0.1.24 description: Serverfree object-oriented microservice architecture. diff --git a/src/artillery/initialize.cr b/src/artillery/initialize.cr index 66f47ff..07d4d09 100644 --- a/src/artillery/initialize.cr +++ b/src/artillery/initialize.cr @@ -5,11 +5,8 @@ module Artillery #de 2. artillery.yml #de 3. Defaults - ENVIRONMENT = ENV["ARTILLERY_ENVIRONMENT"] ||= @@environment + ENVIRONMENT = ENV["ARTILLERY_ENVIRONMENT"] ||= "development" CALLSITE = (ENV["ARTILLERY_CALLSITE"] ||= `pwd`).chomp - unless self.has_constant? :CONFIGURATION - CONFIGURATION = (ENV["ARTILLERY_CONFIGURATION"] ||= "artillery.yml") - end #de Defaults: @@yaml = uninitialized YAML::Any @@ -18,6 +15,8 @@ module Artillery @@mountpoint_port_zeromq = uninitialized String @@mountpoint_port_http = uninitialized String + CONFIGURATION = ENV["ARTILLERY_CONFIGURATION"] ||= "artillery.yml" + @@public_directory = "./public" @@mountpoint_interface = "0.0.0.0" @@mountpoint_port_zeromq = "4000"