Skip to content

Commit d75b60d

Browse files
committed
Using python certify to use ca certs
1 parent d34c37f commit d75b60d

File tree

3 files changed

+9
-11
lines changed

3 files changed

+9
-11
lines changed

rust/crd/src/lib.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
1-
use std::collections::BTreeMap;
1+
use std::collections::{BTreeMap, BTreeSet};
22

3+
use authentication::{
4+
AirflowAuthenticationClassResolved, AirflowClientAuthenticationDetailsResolved,
5+
};
36
use git_sync::GitSync;
47
use product_config::flask_app_config_writer::{FlaskAppConfigOptions, PythonType};
58
use serde::{Deserialize, Serialize};
@@ -322,7 +325,10 @@ impl AirflowRole {
322325
/// components to have the same image/configuration (e.g. DAG folder location), even if not all
323326
/// configuration settings are used everywhere. For this reason we ensure that the webserver
324327
/// config file is in the Airflow home directory on all pods.
325-
pub fn get_commands(&self) -> Vec<String> {
328+
pub fn get_commands(
329+
&self,
330+
auth_config: &AirflowClientAuthenticationDetailsResolved,
331+
) -> Vec<String> {
326332
let mut command = vec![
327333
format!("cp -RL {CONFIG_PATH}/{AIRFLOW_CONFIG_FILENAME} {AIRFLOW_HOME}/{AIRFLOW_CONFIG_FILENAME}"),
328334
// graceful shutdown part

rust/operator-binary/src/airflow_controller.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -883,7 +883,7 @@ fn build_server_rolegroup_statefulset(
883883
.context(GracefulShutdownSnafu)?;
884884

885885
let mut airflow_container_args = Vec::new();
886-
airflow_container_args.extend(airflow_role.get_commands());
886+
airflow_container_args.extend(airflow_role.get_commands(authentication_config));
887887

888888
airflow_container
889889
.image_from_product_image(resolved_product_image)

rust/operator-binary/src/env_vars.rs

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -200,14 +200,6 @@ pub fn build_airflow_statefulset_envs(
200200
AirflowRole::Webserver => {
201201
let auth_vars = authentication_env_vars(auth_config);
202202
env.extend(auth_vars.into_iter().map(|var| (var.name.to_owned(), var)));
203-
env.insert(
204-
"REQUESTS_CA_BUNDLE".into(),
205-
EnvVar {
206-
name: "REQUESTS_CA_BUNDLE".to_string(),
207-
value: Some("/stackable/secrets/tls/ca.crt".to_string()),
208-
..Default::default()
209-
},
210-
);
211203
}
212204
_ => {}
213205
}

0 commit comments

Comments
 (0)