@@ -85,6 +85,8 @@ def supports?
85
85
86
86
private
87
87
88
+ ADDTECHNOLOGIES = 'addtechnologies'
89
+
88
90
APIURL = 'apiurl'
89
91
90
92
APITOKEN = 'apitoken'
@@ -113,12 +115,12 @@ def supports?
113
115
114
116
SKIP_ERRORS = 'skiperrors'
115
117
116
- private_constant :APIURL , :APITOKEN , :ENABLE_FIPS , :DT_APPLICATION_ID , :DT_CONNECTION_POINT , :DT_NETWORK_ZONE ,
117
- :DT_LOGSTREAM , :DT_TENANT , :DT_TENANTTOKEN , :LD_PRELOAD , :ENVIRONMENTID , :FILTER , :NETWORKZONE ,
118
- :SKIP_ERRORS
118
+ private_constant :ADDTECHNOLOGIES , : APIURL, :APITOKEN , :ENABLE_FIPS , :DT_APPLICATION_ID , :DT_CONNECTION_POINT ,
119
+ :DT_NETWORK_ZONE , : DT_LOGSTREAM, :DT_TENANT , :DT_TENANTTOKEN , :LD_PRELOAD , :ENVIRONMENTID ,
120
+ :FILTER , :NETWORKZONE , : SKIP_ERRORS
119
121
120
122
def agent_download_url
121
- download_uri = "#{ api_base_url ( credentials ) } /v1/deployment/installer/agent/unix/paas/latest?include=java " \
123
+ download_uri = "#{ api_base_url ( credentials ) } /v1/deployment/installer/agent/unix/paas/latest?#{ technologies ( credentials ) } " \
122
124
'&bitness=64' \
123
125
"&Api-Token=#{ credentials [ APITOKEN ] } "
124
126
@@ -127,6 +129,18 @@ def agent_download_url
127
129
[ 'latest' , download_uri ]
128
130
end
129
131
132
+ def technologies ( credentials )
133
+ code_modules = "include=java"
134
+ if not credentials [ ADDTECHNOLOGIES ] . empty?
135
+ credentials [ ADDTECHNOLOGIES ] . split ( "," ) . each do |tech |
136
+ code_modules += "&include=#{ tech } "
137
+ end
138
+ end
139
+ return code_modules
140
+ end
141
+
142
+ end
143
+
130
144
def agent_manifest
131
145
JSON . parse ( File . read ( @droplet . sandbox + 'manifest.json' ) )
132
146
end
0 commit comments