File tree 2 files changed +13
-2
lines changed
src/meta/service/src/meta_service
2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -120,6 +120,9 @@ jobs:
120
120
needs : [build, check]
121
121
steps :
122
122
- uses : actions/checkout@v4
123
+ - uses : ./.github/actions/setup_license
124
+ with :
125
+ runner_provider : ${{ inputs.runner_provider }}
123
126
- uses : ./.github/actions/test_metactl
124
127
timeout-minutes : 10
125
128
Original file line number Diff line number Diff line change @@ -212,11 +212,19 @@ impl MetaNodeBuilder {
212
212
213
213
impl MetaNode {
214
214
pub fn builder ( config : & RaftConfig ) -> MetaNodeBuilder {
215
- assert ! ( config. fake_ee_license) ;
216
215
let ee_gate = if config. fake_ee_license {
217
216
MetaServiceEnterpriseGate :: new_testing ( )
218
217
} else {
219
- MetaServiceEnterpriseGate :: new ( config. databend_enterprise_license . clone ( ) )
218
+ // read env var QUERY_DATABEND_ENTERPRISE_LICENSE:
219
+ // - if it is set, use it as the license.
220
+ // - if it is not set, use the license in config.
221
+
222
+ let license = std:: env:: var ( "QUERY_DATABEND_ENTERPRISE_LICENSE" ) ;
223
+ if let Ok ( token) = license {
224
+ MetaServiceEnterpriseGate :: new ( Some ( token) )
225
+ } else {
226
+ MetaServiceEnterpriseGate :: new ( config. databend_enterprise_license . clone ( ) )
227
+ }
220
228
} ;
221
229
222
230
let raft_config = MetaNode :: new_raft_config ( config) ;
You can’t perform that action at this time.
0 commit comments