mirror of
https://github.com/faas-rs/faasd-in-rust.git
synced 2025-06-08 07:55:04 +00:00
fix(get_function):fix the logic of get_function in zky's branch
This commit is contained in:
parent
0bbb6759ce
commit
168b533784
@ -75,7 +75,7 @@ pub async fn get_function(
|
||||
image,
|
||||
pid,
|
||||
replicas,
|
||||
ip,
|
||||
address,
|
||||
labels,
|
||||
env_vars,
|
||||
env_process,
|
||||
|
@ -7,7 +7,7 @@ pub struct Function {
|
||||
pub image: String,
|
||||
pub pid: u32,
|
||||
pub replicas: i32,
|
||||
pub ip: String,
|
||||
pub address: String,
|
||||
pub labels: HashMap<String, String>,
|
||||
// pub annotations: HashMap<String, String>,
|
||||
// pub secrets: Vec<String>,
|
||||
|
@ -35,11 +35,10 @@ impl InvokeResolver {
|
||||
};
|
||||
|
||||
//容器启动后的port?
|
||||
let ip = function.ip.clone();
|
||||
let address = function.address.clone();
|
||||
println!("function: {:?}", function);
|
||||
//let port = 80;
|
||||
|
||||
let urlstr = format!("http://{}", ip);
|
||||
let urlstr = format!("http://{}", address);
|
||||
match Url::parse(&urlstr) {
|
||||
Ok(url) => Ok(url),
|
||||
Err(e) => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user