You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: spu_k8_config.rs
    path of file: ./repos/fluvio/crates/fluvio-sc/src/k8/objects
    
    the code of the file until where you have to start completion: use std::collections::{BTreeMap, HashMap};
use std::fmt;

use anyhow::Result;
use serde::{Deserialize, Serialize};
use tracing::{debug, info};

use fluvio_controlplane_metadata::core::MetadataContext;
use fluvio_types::defaults::SPU_PUBLIC_PORT;
use fluvio_stream_model::k8_types::Env;
use fluvio_stream_model::k8_types::c
    
    fn from(mut data: BTreeMap<String, String>) -> Result<Self> {
        debug!("ConfigMap {} data: {:?}", CONFIG_MAP_NAME, data);

        let image = data.remove("image").ok_or_else(|| {
            anyhow::anyhow!("image not found in ConfigMap spu-k8 data".to_owned())
        })?;

        let pod_security_context =
            if let Some(pod_security_context_string) = data.remove("podSecurityContext") {
                serde_json::from_str(&pod_security_context_string)?
            } else {
                None
            };

        let lb_service_annotations =
            if let Some(lb_service_annotations) = data.remove("lbServiceAnnotations") {
                serde_json::from_str(&lb_service_annotations)?
            } else {
                HashMap::new()
            };

        let service = if let Some(service_data) = data.remove("service") {
            Some(serde_json::from_str(&service_data)?)
        } else {
            None
        };

        let spu_pod_config = if let Some(config_str) = data.remove("spuPodConfig") {
            serde_json::from_str(&config_str)
                .map_err(|err| anyhow::anyhow!("not able to parse spu pod config: {err:#?}"))?
        } else {
            info!("spu pod config not found, using default");
            PodConfig::default()
        };

        info!(?spu_pod_config, "spu pod config");

        Ok(Self {
            image,
            pod_security_context,
            lb_service_annotations,
            service,
            spu_pod_config,
        })
    }