// Enable a specific VPN in the current environment by its ID
481592
func (remoteAccessVpnApi *RemoteAccessVpnApi) Enable(id string) (bool, error) {
	_, err := remoteAccessVpnApi.entityService.Execute(id, REMOTE_ACCESS_VPN_ENABLE_OPERATION, []byte{}, map[string]string{})
	return err == nil, err
}
458576
func (c *Config) allowIP(ip net.IP) bool {
	if len(c.Incoming.allowSubnets) == 0 {
		return true
	}
	for _, n := range c.Incoming.allowSubnets {
		if n.Contains(ip) {
			return true
		}
	}
	return false
}
514564
func (r *Containerd) Enable() error {
	if err := disableOthers(r, r.Runner); err != nil {
		glog.Warningf("disableOthers: %v", err)
	}
	if err := populateCRIConfig(r.Runner, r.SocketPath()); err != nil {
		return err
	}
	if err := enableIPForwarding(r.Runner); err != nil {
		return err
	}
	// Oherwise, containerd will fail API requests with 'Unimplemented'
	return r.Runner.Run("sudo systemctl restart containerd")
}
1111002
func (c *Sys) EnableAuth(path, authType, desc string) error {
	return c.EnableAuthWithOptions(path, &EnableAuthOptions{
		Type:        authType,
		Description: desc,
	})
}
368207
func Enable(addr string) <-chan error {
	errs := make(chan error, 1)

	go func() {
		// The Handler function provides a default handler to expose metrics
		// via an HTTP server. "/metrics" is the usual endpoint for that.
		http.Handle("/metrics", promhttp.HandlerFor(registry, promhttp.HandlerOpts{}))
		errs <- http.ListenAndServe(addr, nil)
	}()

	return errs
}
953967
func (h *NetworkHandler) Enable(c *mech.HTTPDriverContext) {
	h.BaseHTTPDriver.Enable(c)

	h.C.Mux.HandleFunc("GET", "/v1/datapaths/{dpid}/network/interfaces", h.indexHandler)
	h.C.Mux.HandleFunc("GET", "/v1/datapaths/{dpid}/network/interfaces/{interface}", h.showHandler)
	h.C.Mux.HandleFunc("PUT", "/v1/datapaths/{dpid}/network/interfaces/{interface}", h.createHandler)
	h.C.Mux.HandleFunc("DELETE", "/v1/datapaths/{dpid}/network/interfaces/{interface}", h.destroyHandler)

	log.InfoLog("network_handlers/ENABLE_HOOK",
		"Network layer handlers enabled")
}
150086
func (remote *RemoteDebugger) EnableRequestInterception(enabled bool) error {
	if enabled {
		return remote.SetRequestInterception(RequestPattern{UrlPattern: "*"})
	} else {
		return remote.SetRequestInterception()
	}
}
686035
func (s *VPNService) NewResetVpnConnectionParams(id string) *ResetVpnConnectionParams {
	p := &ResetVpnConnectionParams{}
	p.p = make(map[string]interface{})
	p.p["id"] = id
	return p
}
129462
func (s *NATService) EnableStaticNat(p *EnableStaticNatParams) (*EnableStaticNatResponse, error) {
	resp, err := s.cs.newRequest("enableStaticNat", p.toURLValues())
	if err != nil {
		return nil, err
	}

	var r EnableStaticNatResponse
	if err := json.Unmarshal(resp, &r); err != nil {
		return nil, err
	}

	return &r, nil
}
385944
func (u *User) Enable() error {
	if err := u.ensureNotDeleted(); err != nil {
		return errors.Annotate(err, "cannot enable")
	}
	return errors.Annotatef(u.setDeactivated(false), "cannot enable user %q", u.Name())
}
867292
func (_m *FacadeInterface) EnablePublicEndpointVHost(ctx datastore.Context, serviceid string, endpointName string, vhost string, isEnabled bool) error {
	ret := _m.Called(ctx, serviceid, endpointName, vhost, isEnabled)

	var r0 error
	if rf, ok := ret.Get(0).(func(datastore.Context, string, string, string, bool) error); ok {
		r0 = rf(ctx, serviceid, endpointName, vhost, isEnabled)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}
758718
func EnableIPv6Forwarding() error {
	ip6ConfPath := "/proc/sys/net/ipv6/conf/"
	device := "all"
	forwarding := "forwarding"
	forwardingOn := "1"
	path := filepath.Join(ip6ConfPath, device, forwarding)
	return ioutil.WriteFile(path, []byte(forwardingOn), 0644)
}
985310
func (api *API) DeleteVPN(vpn_id string) (*VPN, error) {
	result := new(VPN)
	url := createUrl(api, vpnPathSegment, vpn_id)
	err := api.Client.Delete(url, nil, &result, http.StatusAccepted)
	if err != nil {
		return nil, err
	}
	result.api = api
	return result, nil
}
666822
func (ep *endpoint) enableService() {
	ep.Lock()
	defer ep.Unlock()
	ep.serviceEnabled = true
}
472197
func EnableFastMode(ctx context.Context) context.Context {
	return context.WithValue(ctx, ctxFastModeKey{}, true)
}
1166481
func (s *VPCRouterSetting) DisablePPTPServer() {
	if s.PPTPServer == nil {
		s.PPTPServer = &VPCRouterPPTPServer{}
	}
	s.PPTPServer.Enabled = "False"
	s.PPTPServer.Config = nil
}
454519
func (module *ODroidC1AnalogModule) Enable() error {
	// once-off initialisation of analog
	if !module.analogInitialised {
		module.analogInitialised = true

		// attempt to assign all pins to this module
		for pin, _ := range module.definedPins {
			// attempt to assign this pin for this module.
			e := AssignPin(pin, module)
			if e != nil {
				return e
			}
			e = module.makeOpenAnalogPin(pin)
			if e != nil {
				return e
			}
		}
	}
	return nil
}