xSmurf 9 years ago
parent 21913e9611
commit 319157a1d5

@ -93,7 +93,6 @@ func initialize() *daemonState {
return d return d
} }
func (d *daemonState) loadConfig() (*oz.Config, error) { func (d *daemonState) loadConfig() (*oz.Config, error) {
config, err := oz.LoadConfig(oz.DefaultConfigPath) config, err := oz.LoadConfig(oz.DefaultConfigPath)
if err != nil { if err != nil {
@ -348,7 +347,7 @@ func (d *daemonState) handleNetworkReconfigure() {
d.log.Error("Unable to reconfigure bridge network: %v", err) d.log.Error("Unable to reconfigure bridge network: %v", err)
return return
} }
/* /*
for _, sbox := range d.sandboxes { for _, sbox := range d.sandboxes {
if sbox.profile.Networking.Nettype == network.TYPE_BRIDGE { if sbox.profile.Networking.Nettype == network.TYPE_BRIDGE {
sbox.network, err := network.PrepareSandboxNetwork(d.network, d.log) sbox.network, err := network.PrepareSandboxNetwork(d.network, d.log)
@ -363,6 +362,6 @@ func (d *daemonState) handleNetworkReconfigure() {
// TODO: Reconfigure default gateway inside sandbox // TODO: Reconfigure default gateway inside sandbox
} }
} }
*/ */
return return
} }

@ -226,7 +226,7 @@ func (sbox *Sandbox) whitelistArgumentFiles(binpath, pwd string, args []string,
pmnt := path.Join(binpath, "bin", "oz-mount") pmnt := path.Join(binpath, "bin", "oz-mount")
cmnt := exec.Command(pmnt, files...) cmnt := exec.Command(pmnt, files...)
cmnt.Env = []string{"_OZ_NSPID=" + strconv.Itoa(sbox.init.Process.Pid)} cmnt.Env = []string{"_OZ_NSPID=" + strconv.Itoa(sbox.init.Process.Pid)}
pout, err := cmnt.CombinedOutput(); pout, err := cmnt.CombinedOutput()
if err != nil { if err != nil {
log.Warning("Unable to bind files to sandbox: %v", err) log.Warning("Unable to bind files to sandbox: %v", err)
log.Warning("%s", string(pout)) log.Warning("%s", string(pout))

Loading…
Cancel
Save