diff --git a/conmon-rs/common/proto/conmon.capnp b/conmon-rs/common/proto/conmon.capnp index f2e289f3e0..9cac0e884d 100644 --- a/conmon-rs/common/proto/conmon.capnp +++ b/conmon-rs/common/proto/conmon.capnp @@ -73,6 +73,7 @@ interface Conmon { terminal @3 :Bool; metadataOld @4 :Data; # deprecated metadata @5 :Metadata; # Standard metadata to carry. + envVars @6 :TextTextMap; } struct ExecSyncContainerResponse { diff --git a/conmon-rs/server/src/rpc.rs b/conmon-rs/server/src/rpc.rs index 0c2a669c43..246fc0246a 100644 --- a/conmon-rs/server/src/rpc.rs +++ b/conmon-rs/server/src/rpc.rs @@ -214,11 +214,19 @@ impl conmon::Server for Server { let command = pry!(req.get_command()); let args = pry_err!(self.generate_exec_sync_args(&id, &pidfile, &container_io, &command)); + let env_vars = pry!(req.get_env_vars().and_then(capnp_util::into_map)); Promise::from_future( async move { match child_reaper - .create_child(&runtime, &args, false, &mut container_io, &pidfile, vec![]) + .create_child( + &runtime, + &args, + false, + &mut container_io, + &pidfile, + env_vars, + ) .await { Ok((grandchild_pid, token)) => { diff --git a/internal/proto/conmon.capnp.go b/internal/proto/conmon.capnp.go index 7a83fb6636..4ea6ca8459 100644 --- a/internal/proto/conmon.capnp.go +++ b/internal/proto/conmon.capnp.go @@ -1345,12 +1345,12 @@ type Conmon_ExecSyncContainerRequest capnp.Struct const Conmon_ExecSyncContainerRequest_TypeID = 0xf41122f890a371a6 func NewConmon_ExecSyncContainerRequest(s *capnp.Segment) (Conmon_ExecSyncContainerRequest, error) { - st, err := capnp.NewStruct(s, capnp.ObjectSize{DataSize: 16, PointerCount: 4}) + st, err := capnp.NewStruct(s, capnp.ObjectSize{DataSize: 16, PointerCount: 5}) return Conmon_ExecSyncContainerRequest(st), err } func NewRootConmon_ExecSyncContainerRequest(s *capnp.Segment) (Conmon_ExecSyncContainerRequest, error) { - st, err := capnp.NewRootStruct(s, capnp.ObjectSize{DataSize: 16, PointerCount: 4}) + st, err := capnp.NewRootStruct(s, capnp.ObjectSize{DataSize: 16, PointerCount: 5}) return Conmon_ExecSyncContainerRequest(st), err } @@ -1479,13 +1479,36 @@ func (s Conmon_ExecSyncContainerRequest) NewMetadata(n int32) (Conmon_TextTextMa err = capnp.Struct(s).SetPtr(3, l.ToPtr()) return l, err } +func (s Conmon_ExecSyncContainerRequest) EnvVars() (Conmon_TextTextMapEntry_List, error) { + p, err := capnp.Struct(s).Ptr(4) + return Conmon_TextTextMapEntry_List(p.List()), err +} + +func (s Conmon_ExecSyncContainerRequest) HasEnvVars() bool { + return capnp.Struct(s).HasPtr(4) +} + +func (s Conmon_ExecSyncContainerRequest) SetEnvVars(v Conmon_TextTextMapEntry_List) error { + return capnp.Struct(s).SetPtr(4, v.ToPtr()) +} + +// NewEnvVars sets the envVars field to a newly +// allocated Conmon_TextTextMapEntry_List, preferring placement in s's segment. +func (s Conmon_ExecSyncContainerRequest) NewEnvVars(n int32) (Conmon_TextTextMapEntry_List, error) { + l, err := NewConmon_TextTextMapEntry_List(capnp.Struct(s).Segment(), n) + if err != nil { + return Conmon_TextTextMapEntry_List{}, err + } + err = capnp.Struct(s).SetPtr(4, l.ToPtr()) + return l, err +} // Conmon_ExecSyncContainerRequest_List is a list of Conmon_ExecSyncContainerRequest. type Conmon_ExecSyncContainerRequest_List = capnp.StructList[Conmon_ExecSyncContainerRequest] // NewConmon_ExecSyncContainerRequest creates a new list of Conmon_ExecSyncContainerRequest. func NewConmon_ExecSyncContainerRequest_List(s *capnp.Segment, sz int32) (Conmon_ExecSyncContainerRequest_List, error) { - l, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 16, PointerCount: 4}, sz) + l, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 16, PointerCount: 5}, sz) return capnp.StructList[Conmon_ExecSyncContainerRequest](l), err } @@ -4032,197 +4055,198 @@ func (p Conmon_createNamespaces_Results_Future) Response() Conmon_CreateNamespac return Conmon_CreateNamespacesResponse_Future{Future: p.Future.Field(0, nil)} } -const schema_ffaaf7385bc4adad = "x\xda\xb4Y{\x90\x14\xd5\xd5?\xa7\xef\xcc\xf6\xce\xb2" + - "8\xdb_\xcf\xc2\xba\xb5|\x8b\x08~\xc0\x17\xe4\xb1\x18" + - "\x09\x85\xc5\xf2\xd8B\x08\xea\xf6\x0ej\"\xc1\xa2w\xa6" + - "\xd9\x1d\x9c\x99\x1e\xba{\x80E\x0d>BEPT6" + - "X\x0a\x15\xab@\xc1\x02\"Qc0\x82`\x89Ji" + - "P\x92@\x94\x18K4\x88DC\xf9\"\x9a\x0aX\x9a" + - "N\x9d\xdb\xd3\x8f\x9d]qfc\xfe\xa0v\xfa\xf4\xaf" + - "\xcf\xb9\xf7\xdc\xf3\xf8\x9d\xcb\xb8C\x95\xcd\xa1\xf1\x03\x07" + - "\x0f\x04Ay \\a\x9b\xc7\xbb\x8cG\x1e\x9cu;" + - "H\x17\"@\x18E\x80\xa6%\x15\xef\"\xa0\xbc\xaab" + - "*\xa0\xfd\x8f-/_v\xff\xbaO\xd6\x04\x01[\x1d" + - "\xc0n\x0exk\xd2\xe8E\x9b\xd8\xdc;\x83\x80c\x15" + - "o\x12\xe04\x07\xfcxat\xfd\xcf\x06\xcd\xe7\x00\xfb" + - "t\xd3\xa2c\x1b>\xb8\xf47\x10\x16\x09(\x89o\xa2" + - "<\x86\xff\x1c%\xde\x83\x80\xf6+\xff\xbb\xe2\xda\xe8#" + - "?}\xa0\x08\xcd\xd5F\"\xef\xa2<\"\"\x02\xc8\x17" + - "DH\xf5\xaa\xbf]\xf9\xd4\xd5\xb7\x7f\xb2)h\xfb\xea" + - "\xc8\xdf\xc9v\x8a\x036\xcc\xff\xe0\x86\x96\xd9\xd1\x87z" + - "j\x0b\x11nmd\x07\xca[#\"0{\xd0\x17'" + - "\xb6\x1c\x8dO\xda\x0e\xca\x85\xd8\xcb\xe8\xad\x84\xdb\xc0\x8d" + - "\xde\x17Y\x06h\x0f\x7f\xec\x85\xc3k\xa6\x8c\xdd\x114" + - "z:r\x84\x8c\x86\xab\xc8\xe8\xb2\x85/?\xb6B9" + - "\xf9h\x1fFGTu\xa3|Y\x15\x19\x95g\x8e\xdb" + - "}\xb4i\xf4\xceb\xa3\x02\xe1\xce'\xdc\xf8*2:" + - "\xa6\xea1@{\xe2\xe6'\x9f\xba\xfb\xe3\xe5\xbf$\xb4" + - "P\xbc\xc4cU\x8bQ>]5\x18@>\xcb\xd17" + - "\x1e>\xb5\xed\xee;\xa7\xed*\xd6\xcd\x08\xbdn\xc0\xf3" + - "(o\x1f\xc0\x0fr@#\xf9\xdc\x03H\x0d\xcc\xde\xb9" + - "\xf3\xc5\xf9\x93\xfe\xb9\xc3\x06\xc0\xa6C\xd5\xf5\xd8t\xac" + - "\xfa\xff\x10\xa0\xe9\x92\xf3^B9\x1f\x15\x01\xec\x83O" + - "m\x9f\xfc\xc5\x89e{\x8a\xd5s\x9d\x0b\xa2GP\xee" + - "\"\\S>\xfa\x8e\x00h\xd7\xcc\xff\xfde\x1f^\xff" + - "\xd7\x03A\x87\x0d\x94y\x84\\ \x93\xc3\xdeW\x9f\x11" + - "Z\x0e\xa5_\x0a\x02Z\xe4*\x01P^\xe0\x00\xde\xfb" + - "\xd7\xe2\x8e\xdc\xd8W\x83\x80\x9b\xe5n\xd2\xb0\x96\x03\xce" + - "\xd4>{\x7f\xfd\x94=\xbf\x0b\x02v:&\xf6s@" + - "\xfd\xb4\xc3\x13\xa3\xd9Y\x7f(\x0a+\xee\x90\x93\xf2C" + - "(\x7f%\x93\xb3\xcf\xca\xe4\xbe\x87?\xdb\xb6p\xd7\xba" + - "\xd8Q\x90.\x0c\xf8\x1a\xb0i{l1\xca\xfbb\x84" + - "\xdc\x1d[\x09h\x7f\xb9j\xca-C\x86\x1c\xfds\x9f" + - "\x87\xf8Q\xec\x14\xca\x91ZB\x87k\xdf\x07\xb47\xfe" + - "\xff\xb2\xdc\xf5\xed\x93\xdf.B\xf3\xc88^\xfb&\xca" + - "_q\xf0\xd9ZZ\xf1\x97\x93\xbf|v\xd3\x94\xdc;" + - "\xc5\xaa\xc3\x84\x1e2h\x0d\xca\x97\x0c\xa2\x9f\xe3\x07]" + - "Kgxun\x96tQ\xdby\x7f\xe9\x91\xa7\x83\xff" + - "\x87|\xb8o0\xe9\x1bw\xe3\xac\xed\xd7\xa7\xe4\x13A" + - "\xc0\xf1\xc1\x1by\x9er\xc0w\xe5\x17\x1e\xcf\xae;u" + - "2\x08\xa8\xad;E\x80Qu\x04\xd8?\xbf\xa9\xf5O" + - "'.\xfa\x14\xa41\x82\x1f\x90\x80M\xb3\xeb\xbaQV" + - "\xebh\xed\x0b\xea\x1a\x01\xed\xc3\x1f7>\xfa\xca\xc9\xef" + - "\x7fV\xbc\xf6\x08\x0f\x90\xba\x8d(\xe7\xebx\xa5\xa9\xbb" + - "\x94\x02\xe4\x91%\x0f\xdf{f\x98\xf4yqps\xc7" + - "\x1c\xa8\x7f\x17\xe5\xe3\xf5<\xce\xeb\xf9V\x9f\xde\xb8\xfe" + - "\x9e\x17'\xcc\xfa<\xb8\xd0\x1f6\xf0\x04\xcc4\xd0B" + - "\xf7\xe2\x8e\x01?Z\xfc\xc1\x99 `m\x03\xdf\xc9f" + - "\x0e8\xb3\xf9\x17M\xb7\x1cz\xf2l\x1f\x19z\xa0\xe1" + - " \xca\xc7\x1b(C\xbb\xff8'\xf3\xf6W\xcf|Q" + - "\x143\xfcl\xf75<\x84\xf2\xeb\x0d\xb4\xe5\xc3\x0d\xcb" + - "`\x8c\x9d\xcaZ\x9a\x91U\xd3\x15cs\x86n\xe9c" + - "\x13z6\xa3g/N\xa8\xb9ln\xf2\x0c\xe7A[" + - "\xae%\xe2]\xd9\xc4\x0c=k\xa9\xa9\xacf\x0coU" + - "\x0dQ\xcd\x98J\x88\x85\x00B\x08 \x0d\x9c\x0e\xa0T" + - "2Tb\x02\xae4\xb4%y\xcd\xb4\xb0\xc6w\x11 " + - "\xd6\x00\x96d.ah\xaa\xa5]\xa9f43\xa7&" + - "4sx\x9bf\xe6\xc5\xb4\xd5\xc3\xdc\x1c\x00\xa5\x9a\xa1" + - "R'\xa0mhfN\xcf\x9a\x1a\x00`\x8d_\x89\xff" + - "\x13\x93\xad\xaa\xa1\xb2R6\xe8u\x892\xac\xcd(\xb2" + - "\xd6F\xda\x98i\xb5\"*\x0d\x9e\xc1]\xed\x00\xca\xaf" + - "\x19*\xcf\x09(!\xc6\x90\x84\xfb\xae\x03P\xf62T" + - "\xde\x10P\x12\x84\x18\x0a\x00\xd2\xeb\x84|\x8d\xa1\xf2\xa9" + - "\x80\x12c1d\x00\xd2G$\xfc\x90a\xbc\x12\x05\x94" + - "B\xa1\x18\x86(\xa1q\x0e@<\x84\x0c\xe35$\x0f" + - "\x87c\x18\x06\x90\x07\xe2\x04\x80x%\xc9c$\xaf\xa8" + - "\x88a\x05\x80,q|\x0d\xc9\xbf\x83\x02\xda\x19\xcdR" + - "\x93\xaa\xa5\x82xU:\x89\x03A\xc0\x81\x80v\xb6\xb0" + - "\x15`\x9a\x89\xe7\x01\xb62\xc4\xa8_\x8e\x00Ih\xe7" + - "S\xc9+\xd4\\.\x05b\xb6\xc3\x83U\x83\xc0_v" + - "\x9c\xebe\xbbjj\xad\xaa\xd5I\x07L\xb2j\xc0\xc6" + - "\x9c\x9e\x9c\x9dt\x9f\xfcu\x01\xb8\x1f\xd7\xf8\x89PX" + - "@\xff\xce\xc6\xcc\xe9b\xd6\xd4\xe8p\x02\xd1p]!" + - "\xfeF\x0a}o\xbf\xc6\xef\xceeX74=\xa7e" + - "\xe7\xea\x1d~\xaa\xb5i\x8df\xbe\xe4\xe0\xf7\x88CQ" + - "8\x86\xcfa\xb4\xcd5J{\x8d\xea\xce^K\xfa\xd2" + - "sS\xf0K\xa5\xd2[\xe8\xa8\xd1\x00\xcap\x86\xca8" + - "\x01\xdd\x08\x1eC\xb2\x91\x0c\x95\x89\x02F\xad\xae\x9cV" + - "\x14)Q\xc0hN\xb5:\xbd\xa3-\xc5o\xaae\xa9" + - "\x89\xce\x1e\xf5I\xcd`\x09\xe9\xebu\xab2\xfc5\x8d" + - "\x1bks\xfc\x8e%;\xeb\x1a\xcd0Sz\x96'\xbb" + - "\x89<\xd9\xab\xbd\xe5\xb5\xd0\xf2\x9a\x19*s}O\xcd" + - "\xa6\x0c\xbe\x9c\xa12\x8fr\x1d\x9d\\W\xe8\xec[\x19" + - "*i\x01W.\xd5\x8cv\xdd\xd4\x10A@\x84\xaf\xcb" + - "\xce\xb2r#t\x8e\x1d\xcc\xd5;f\x1a\xd1\xd4R\xcd" + - "PB\x18\xec\xab8::\xaf+\xa7\x05\xf73\xba\x8f" + - "\xfd\x90l&C\xa55\xb0\x9f+\xa6\xfb\x9bt\xc3\xc1" + - "S\xdcG8\xac\xcc\xa8\xcb\xe3\xa9\x15\x1aF@\xc0H" + - "\x89\xe1\x11\xd7\xackS\xd9\xa4\xbe\x8c\xbet\x0e\xc0\x02" + - ":\x80\x98\xb7\xe0\x9b\xeb\x01\x94\xe5\x0c\x95\x9f\xf8\x0b\xbe" + - "u\x02\x80r\x13C\xe5\x8e\xc0\x82WM\x06Pna" + - "\xa8\xdcE\xc5\x16\x9db\xbb\x9a\x8e\xea\x0e\x86\xcaz\xaa" + - "\xb5\x02\xaf\xb5\xd2::\xaa{\x19*\x8f\x0a\xc8R^" + - "\xadj\\\x96JZ\x9d(\x82\x80\"\xe0\xd4N-\xd5" + - "\xd1i\xb9\x8f\xdf\xc6\x11\xb2\xaf\xf3\x04\xd3\xb3\xca\xe5\x88" + - ">\x85\x97V\xaf\xf09\x8f\xb4\xfa6\x9f!K\xab\xf7" + - "\xf8TIZ\xdb\xe6s@i\xed\xf3~W\x97\xd6\x1d" + - "\xf4\xb9\xa4\xb4\xe1\x88\x9fO\xd2f#0Pl^\x11" + - "`\xb2\x9b\xd7\x04\xe6\x9b\xad\xdd>\xeb\x97\xb6\xef\x08P" + - "\x9c\x9d\xbf\x0a\x8c`O<\x1f`\xb7\xbb\xda\x02\xe3\xd6" + - "\xae\x83~\xa5\x95\xf6u\x07\xd8\xcf\xfe5\xb6\x9bs0" + - "\xd59tO\xc0\xdc\xaa\xe9\xd4{\xafr\xb4\xb9@\x1e" + - "\xeb\xa9\xa5\x1a\xa0a\xbb\x98\xb0\x0br?n)&F" + - "nl\x81\xed\xbe\x12\x02\xef\x0a\x05\xc3v\x0b\x084:" + - "\xb6\xbc\xe7\xa9\x8e^\xdb\xad\xc8\xd8\xe1+\x0c\xca\\E" + - "n\\\xa3\x1b\xd8Q\xae\xafXl6:j\xdd\xde\xc6" + - "z\x10\x0f\xd3\x02\xb7\x8e\xa3\x8f\x11z4@\xde_l" + - "\x1f\xe6/a\x9e\xb6\xdc\xa2\x7fx\x85\x9ak\xc9ZF" + - "\x17\x80\xd2\xc0\xc2\x00\xde\xf0\x83.\x83\x97\x0eO\x07A" + - ": \xa2O\x85\xd1\x1d\x80\xa4\xdd\xb7\x81 =!\xa2" + - "\xe0\x8d\xf6\xe8\xd2aik7\x08\xd2f\x11\x997\xc3" + - "\xa2;\x9bI\xf7\xd1wkE\x0cys\x00\xba\xd3\xb5" + - "t\xebF\x10\xa4\x9bE\x0c{\x93\x1a\xba\xe3\x86\xb4d" + - "\x0f\x08RF\xc4\x0a\xef\"\x00\xdd+\x03I]\x03\x82" + - "\xb4@\xa4\xf2J\xc1\xd2\x8cv\xa2\x10\x01X8Kh" + - "F\xdbe\xc5\xe8\x9e0\x1a\xcdh\xbb\x9d(\x884\xbc" + - "\xa3+@\x99FP\xb3\xc71\xcd\xd0\xb3S\x9dO<" + - "{W\xaa\xe8\x9e\x02@3\x06\x1b\xcd7S\x98\xa2\x98" + - "t\x1a\xceD\xb7\xde\xc9\x0b\xb0\x1e \xfe\x03\"vI" + - "\xf4\x09\xa6\xac\xe2u\x00\xf1\x85$O\xa3\x80\xe8PL" + - "9\xc5y`'\x89-\xf4\x0b\x9f\xbc\x84\xf3\xc64\xc9" + - "\x97\xa3_\xfb\xe4<\xb6\x01\xc4-\x92\xdf\xcby&s" + - "x\xe6Z\\\x0c\x10\xbf\x8b\xe4\xdb8\xcf\x0c9\x94\xe4S\x84\x1e" + - "\xe5\xdbn\xcfg\x93i\xadU\x05\x16 )\x96fd" + - "RY5M\x05\xba\xd0\x8d\x1bM+\x99\xcaz\xbdY" + - "[\x9e\xb28\x87\xc5^\xf4V\xd73-\xf4\x16\xa2\xaa" + - "\xd5\xd9\xebm\xda\xadD\xcc\x08\xb0\xcb\xc0\x1c\xcbQ\x89" + - "\xb4\xa6f\xf3\xb9\x19\xc02\xc9^\xdc:\xad\xb7\xab\xe9" + - "i\x06\xb0\xde\xd4:\xa1g2j69\x0dD\xa3\xf7" + - "\xcb\xfe7\xa3\x95Zv\xe95jp\xc1\xfd!\xe3\xc5" + - "\xb4\x8e\x06\xc14+\x95\x0b{\xed\xa7\x88\xdb\x89\xe7\xb0" + - "h\x06\x99B\x11\x9f4\x01\xbe\x99Pz\xcd\xac\x0cB" + - "Y\xa83\xa5\xb3V\xaf\x81\x97=\xe2\xf6\xd7\x97^\xfb" + - "\xef\xdf\\\xb1$/jf1\xe5\xad\xf7)\xa2\xd47" + - "\xe7\x15zs\xde`&\xfe\x97\xe9.owQ*\xbf" + - "\x9c*\xf2\xa5\\2\x8c4Hc\xe8\x8f \x8d\xa0?" + - "L\x1a2\x1a\x00CR\xed0\x001\x95K\x88Y\xcd" + - "\x12s\xa9d4oj\x86\x98\xb7\xcc\x92\xce\xa7\x0f." + - "\x11\x98\xa9j<\xb7\xa9\xe4\x8c\x85\x8e3\\\xaf\xa5\x88" + - "\x93&\x19*\xb9\x00Q\xcd\x90\xb0\x93\xa1bQ\xbd\x1e" + - "\xea\x10\xd5%\xf4u\x8e\xa1r\x93\xe0\x94\xa4\x19z\x92" + - "\x1fq\x08\x04\x0c\x01N5\xad\xa4\x9e\xb7\\g\xd2\xa3" + - "f\x18\x9eo\xadTFK^\x95\xb7\x02e\xae\x7f-" + - "\x89b\x8b\xf5\x1a\xaa\x17\x07\xe2/Q\x00C\xd4hM" + - "%\xb1\x12\x04\xac,s@+P'2R\xe7\x19\xd9" + - "@a\xb7\x9e\xa1\xb2)\x10v\x0f\xd28\xffs\x86\xca" + - "\xb6@\xd8m5\x00\x94-\x0c\x95\xc7\x05\xc4\xc2\xad\xca" + - "\xcen\x00\xe5q\x86\xca^jv\xcc!\xfa\xbb)h" + - "\x9ff\xa8\xbcH\x9d.\xc4;\x9d\xb4\x9f<\xfd\x1cC" + - "\xe5\xad\x9eAk\xea\x89\x1b4\xab\xa8}p.\xa1\x99" + - "&4\xa6\xf4l\xe0Z\xc3\xb4\xf4\xdc\xb4E\x96\x86F" + - "\x9c\x9aI\x8b\x8e\x8b\xbe\xcda\xaf\x1f\x95\x90\x97\x0d\x0b" + - "K,\x1b\x1e\x9b\xefG5,\xaf@ycL\x19%" + - "\xb1\x8f\xdb\x96V5j\x94t\xb1\xe9\x8d3e\xec\xcc" + - "\x9d)\x8c\x8b\xe7u\xe5\xd0\x09~\x1ei\xe1#\x00^" + - "\xc0\x0bF[>K\x896\x9bT.\xe2\xac\xbc\xac\xfb" + - "\x85@n\x8d\xf4\xf8^\x84\x132\xef\x82\xcf\xa5{\x12" + - "\x12\xcf\xa9&q\x1d\xfa\xc5C\xae\xc5a\xee\xbd_\x03" + - "\xe7{\x82\xc3\xf7\xce\xc7\xc9\x00\xf1\x18\xc9\x87\xa2\x9f\x02" + - "\xf2\x10\xae\xbe\x81\xe4#\xd1\xcf\x02y\x04\xc7\x0fu\xef" + - "\x0f\xa5\x8a\xb0\xc3\xf7Fq\x9e6\x92\xe4\x139\xdf\xab" + - "p\xf8\xdex\xce\x0f\xc7\x91|\x0a\xe7{\xa2\xc3\xf7\xbe" + - "\xc7\xf5O\"\xf9L\xce\xf7*\x1d\xbe7\x8d\xf3\xd2f" + - "\x92\xcfE\x01\xed\x9c\xa1'4\xd3\x9c\x0d\xe8\x95\x0c\x97" + - "\xc6\xbbI%Zj\x87\xfb{*\xd1\x9f\x94\x15\xe0v" + - "\xa9tr\xa6j\x01j\x1e\xc4R\x8d\x0e\xcd\x87\x18y" + - "\xd3\"W\x83\x18\xd0i'T\xa3C\xbfF3 j" + - "\xf6\x12\xcf3\xb4\x80\xbe\x1e\x19\xeafm?\x1b\x84\xdf" + - "V\xfb\xaeo}\x97\xb7B\x7f\xd8J\x81\xbd\xa9P\xca" + - "X\xb3S\xdfv\xcf\x09\x942\xf7\"c\x7f{\xa1\x94" + - "\xbd\xea3y\xe9\xb7\x84|\x99\xa1\xf2^\xcf\xfaF\x91" + - "\xab\xe7\xad80-\xe1^\xd2\xac,\xb0\xccb~\xd9" + - "\x07k\xfe6\xcaZ94\xa8d\xce\xe5]\x8d\x94Q" + - "`z\xff\xc7I\x9bfFK\xbf\xcd\xf5\xaeV\xca\xb0" + - "Yt\xd7\xe5\xaa+\xf5\x96\xd2\x9d\xe7\xf98/ZF" + - "W\xd1\x8d\xee0\xffF\xd7\xeb\x9ec&\xf8W\xba\xe2" + - "\x0dZ\x97w\xd3\xb5TM\xe7\xbd\xc0\xffw\x00\x00\x00" + - "\xff\xffu\xbe\xe8a" +const schema_ffaaf7385bc4adad = "x\xda\xc4Y{\x90\x14\xd5\xd5?\xa7\xef\xcc\xf6\xce\xb2" + + "8\xdb_\xcf\xc2\xba\xb5\xfb-\"\xf8\x01_V\x1e\x8b" + + "\x91PX,\x8f-\x84\xa0n\xef\xa0\xa6 X43" + + "\xcd\xee\xe0\xcc\xf4\xd0\xdd\x03,j\xf0\x11*\x82\xa2\xb2" + + "\xc1R\xa8X\x05\x0a\x16\x10\x89\x1a\x83\x11\x04K|\x94" + + "\x16\xc6$\x10%j\x89\x8aH$\x94\xa8DS\x01K" + + "\xd2\xa9s{\xfa\xb1\xb3+\xcenL\xe5\x0fj\xa7O" + + "\xff\xfa\x9e{\xcf=\x8f\xdf9\x8c\xf9\xa0\xbc94v" + + "\xe0\xe0\x81 (\x0f\x86\xcbl\xf3h\xa7\xf1\xe8C3" + + "\xee\x00\xe9b\x04\x08\xa3\x08\xd0\xb4\xa4\xecC\x04\x94W" + + "\x95M\x06\xb4\xff\xbe\xe5\xd5+\x1eX\xf7\xd9\x9a `" + + "\xab\x03\xd8\xcd\x01\xefN\x18\xb5h\x13\x9b}W\x10p" + + "\xa4\xec\x1d\x02\x9c\xe6\x80\x9f,\x88\xae\xff\xf9\xa0y\x1c" + + "`\x9fnZtd\xc3\x89\xcb\x7f\x0ba\x91\x80\x92\xf8" + + "\x0e\xca\x8d\xfc\xe7H\xf1^\x04\xb4_\xfb\xdf\x15\xd7G" + + "\x1f\xfd\xd9\x83Eh\xbel$\xf2!\xca\xc3#\"\x80" + + "|Q\x84\x96^\xf5\xd7\xab\x9f\xbe\xf6\x8e\xcf6\x05u" + + "_\x1b\xf9\x1b\xe9Nq\xc0\x86y'nl\x99\x19}" + + "\xb8\xfbj!\xc2\xad\x8d\xec@ykD\x04f\x0f\xfa" + + "\xea\xd8\x96\xc3\xf1\x09\xdbA\xb9\x18{(\xbd\x8dp\x1b" + + "\xb8\xd2\xfb#\xcb\x00\xeda\x8f\xbfxp\xcd\xa4\xd1;" + + "\x82JOG\x0e\x91\xd2p\x05)]\xb6\xe0\xd5\xc7W" + + "(\xc7\x1f\xebE\xe9\xf0\x8a.\x94\xaf\xa8 \xa5\xf2\xf4" + + "1\xbb\x0f7\x8d\xdaY\xacT \xdc\x85\x84\x1b[A" + + "J\x1b+\x1e\x07\xb4\xc7o~\xea\xe9{>]\xfe+" + + "B\x0b\xc5[\xfa\xbe\x00hW\xcd\xfb\xc3\x15\x9f" + + "\xdc\xf0\x97\x97\x83\x06\x1b(s\x0f\xb9H&\x83}\xac" + + ">+\xb4\xbc\x9e~%\x08h\x91+\x04@y\xbe\x03" + + "\xf8\xe8\x9f\x8b\xdbs\xa3\x7f\x17\x04\xdc\"w\xd1\x0ak" + + "9\xe0L\xf5s\x0f\xd4N\xda\xf3\xfb `\xa7\xa3b" + + "?\x07\xd4N98>\x9a\x9d\xf1\xc7\"\xb7\xe2\x069" + + ".?\x8c\xf29\x99\x8c}V&\xf3=\xf2\xc5\xb6\x05" + + "\xbb\xd6\xc5\x0e\x83tq\xc0\xd6\x80M\xdbc\x8bQ\xde" + + "\x17#\xe4\xee\xd8J@\xfb\xebU\x93n\xad\xaf?\xfc" + + "v\xaf\x97x*v\x12\xe5H5\xa1\xc3\xd5\x1f\x03\xda" + + "\x1b\xff\x7fY\xee\x86\x85\x13\xdf+Bs\xcf8Z\xfd" + + "\x0e\xca\xe78\xf8l5\xed\xf8\xeb\x89_?\xb7iR" + + "\xee\xfd\xe2\xa5\xc3\x84\xae\x1f\xb4\x06\xe5\xcb\x06\xd1\xcf\xb1" + + "\x83\xae\xa7;\xbc67C\xba\xa4\xed\x82\x0f\xba\xc5\xe9" + + "\xe0\xff!\x1b\xee\x1bL\xeb\x8d\xb9i\xc6\xf6\x1bR\xf2" + + "\xb1 \xe0\xe8\xe0\x8d\x9bLk\xad*\xb0\x00I\xb14" + + "#\x93\xca\xaaiJ\xd0\x85j\xdc`Z\xc9T\xd6\xab" + + "\xcd\xda\xf2\x94\xc59,\xf6\xa0\xb7\xba\x9ei\xa1\xb7\x10" + + "U\xad\x8e\x1eo\xd3n&bF\x80]\x06\xfaX\x8e" + + "J\xa455\x9b\xcfM\x03\x96I\xf6\xe0\xd6i}\xa1" + + "\x9a\x9eb\x00\xebI\xad\x13z&\xa3f\x93S@4" + + "z\xbe\xec\x7f1Z\xa9e\x97^\xa7\x067\xdc\x1f2" + + "^L\xeb\xa8\x11L\xb3R\xb9\xb0W~\x8a\xb8\x9dx" + + "\x1e\x8df\x90)\x14\xf1I\x13\xe0\xdb\x09\xa5W\xcc\xfa" + + "@(\x0by\xa6t\xd6\xea\x15\xf0>\xb7\xb8\xfd\xb5\xa5" + + "W\xfe\xfb\xd7W,\xc9\x8b\x9aYLyk}\x8a(" + + "\xf5\xcey\x85\x9e\x9c7\x18\x89\xffa\xba\xcb\xcb]\x94" + + "\xd2/\xa7\x8a|+\x97\x0d\xa5\x15\xa4F\xfa#H\xc3" + + "\xe9\x0f\x93\xeaG\x01`H\xaa\x1e\x0a \xa6r\x091" + + "\xabYb.\x95\x8c\xe6M\xcd\x10\xf3\x96Y\xd2\xfd\xf4" + + "\xc2%\x02=U\x95g6\x95\x8c\xb1\xc01\x86k\xb5" + + "\x14q\xd2$C%\x17 \xaa\x19\x12v0T,\xca" + + "\xd7C\x1c\xa2\xba\x84\xbe\xce1Tn\x16\x9c\x944M" + + "O\xf2+\x0e\x81\x80!\xc0\xc9\xa6\x95\xd4\xf3\x96kL" + + "z\xd4\x0c\xc3\xb3\xad\x95\xcah\xc9k\xf2V \xcd\xf5" + + "\xaf$\x91o\xb1\x1eM\xf5\xe2\x80\xff%\x0a`\x88\x1a" + + "\xad\xa9$\x96\x83\x80\xe5}l\xd0\x0a\xd4\x89\x94\xd4x" + + "J6\x90\xdb\xadg\xa8l\x0a\xb8\xddC\xd4\xce\xff\x82" + + "\xa1\xb2-\xe0v[\x0d\x00e\x0bC\xe5\x09\x01\xb10" + + "U\xd9\xd9\x05\xa0<\xc1P\xd9K\xc5\x8e9D\x7f7" + + "9\xed3\x0c\x95\x97\xa8\xd2\x85x\xa5\x93\xf6\x93\xa5\x9f" + + "g\xa8\xbc\xdb\xddiM=q\xa3f\x15\x95\x0f\xce%" + + "4\xd3\x84\x86\x94\x9e\x0d\x8c5LK\xcfMYdi" + + "h\xc4\xa9\x98\xb4\xe8\xb8\xe8\xbbl\xf6\xfa\x91\x09y\xda" + + "\xb0\xb0\xc4\xb4\xe1\xb1\xf9~d\xc3\xbe%(\xaf\x8d\xe9" + + "CJ\xece\xda\xd2\xaaF\x8d\x92\x06\x9b^;\xd3\x87" + + "\x93\xb9=\x85q\xe9\x9c\xce\x1c:\xce\xcf=-|\x08" + + "\xc0sx\xc1h\xcbg)\xd0f\xd2\x92\x8b8+\xef" + + "\xd3|!\x10[#<\xbe\x17\xe1\x84\xcc\x1b\xf0\xb9t" + + "OB\xe29\x95$\xaeA?y\xc8\xd58\xd4\x9d\xfb" + + "\xd5q\xbe'8|\xefB\x9c\x08\x10\x8f\x91|\x08\xfa" + + "! \xd7\xf3\xe5\xebH>\x02\xfd(\x90\x87s\xfc\x10" + + "w~(\x95\x85\x1d\xbe7\x92\xf3\xb4\x11$\x1f\xcf\xf9" + + "^\x99\xc3\xf7\xc6r~8\x86\xe4\x938\xdf\x13\x1d\xbe" + + "\xf7\x03\xbe\xfe\x04\x92O\xe7|\xaf\xdc\xe1{S8/" + + "m&\xf9l\x14\xd0\xce\x19zB3\xcd\x99\x80^\xca" + + "pi\xbc\x1bT\xa2\xa5\xb6\xbb\xbf'\x13\xfdIY\x01" + + "n\x97J'\xa7\xab\x16\xa0\xe6A,\xd5h\xd7|\x88" + + "\x917-25\x88\x815\xed\x84j\xb4\xeb\xd7i\x06" + + "D\xcd\x1e\xe29\x86\x16X\xaf[\x84\xbaQ\xdb\xcf\x02" + + "\xe1\x97\xd5\xc0\xd8\xb8\xd6\xcfPnz\xdb=7\x90\xa0" + + "\xdc\xfa\xb0\x7fj`\x94\xcc\x9a\x9d\xfc\xf6\xe6\xac\xc2(" + + "\xf9\x83\xc0 \xe3\x08\xe5\xb7w\x19*'|&/\x1d" + + "'\xe4G\x0c\xdb\x024^:Gk\x9e)\xf8X0" + + "\xeb\x91?\xeby+\x0eLK\xb8\xa3\x9b\x95\x05\xeeY" + + "\xcc:{\xe1\xd2\xffu&Z\xcc\x9eJ\xa6j\xdeD" + + "\xa5\x0fy\xa9\xe7\xff\xb7\xb4if\xb4\xf4!\xb07\x91" + + "\xe9\x83\xce\xa2\x11\x99\xbb\\\xa9\xc3Mw\x0c\xc0\xa7\x00" + + "\xa2et\x16\x0d\x82\x87\xfa\x83`\xaf\xe86\x8e\xf3'" + + "\xc1\xe2\x8dZ\xa77 [\xaa\xa6\xf3^\xbc\xfc+\x00" + + "\x00\xff\xff\x99\x96\xf5/" func RegisterSchema(reg *schemas.Registry) { reg.Register(&schemas.Schema{ diff --git a/pkg/client/client.go b/pkg/client/client.go index 078baf8dca..9383117338 100644 --- a/pkg/client/client.go +++ b/pkg/client/client.go @@ -759,6 +759,9 @@ type ExecSyncConfig struct { // Terminal specifies if a tty should be used. Terminal bool + + // EnvVars are the environment variables passed to the exec runtime call. + EnvVars map[string]string } // ExecContainerResult is the result for calling the ExecSyncContainer method. @@ -810,6 +813,9 @@ func (c *ConmonClient) ExecSyncContainer(ctx context.Context, cfg *ExecSyncConfi if err := p.SetRequest(req); err != nil { return fmt.Errorf("set request: %w", err) } + if err := stringStringMapToMapEntryList(cfg.EnvVars, req.NewEnvVars); err != nil { + return err + } return nil })