code: func CreateOptionPortMapping(portBindings []types.PortBinding) EndpointOption {
  	return func(ep *endpoint) {
  		// Store a copy of the bindings as generic data to pass to the driver
  		pbs := make([]types.PortBinding, len(portBindings))
  		copy(pbs, portBindings)
  		ep.generic[netlabel.PortMap] = pbs
  	}
  }
docs: // CreateOptionPortMapping function returns an option setter for the mapping
  // ports option to be passed to network.CreateEndpoint() method.