- Fix target delete URL path mismatch (/targets/ -> /target/) - Implement target create/delete server handlers with proper validation - Add DeleteTarget method with force flag and mutex locking to SCSITargetService - Implement full LU management: create/list/delete through CLI, client, and server - Add TPGT list command to show target portal group tags - Add unit tests for target/LU router handlers and SCSI service Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
14 lines
323 B
Go
14 lines
323 B
Go
package client
|
|
|
|
import (
|
|
"github.com/gostor/gotgt/pkg/api"
|
|
"golang.org/x/net/context"
|
|
)
|
|
|
|
// LuCreate creates a LU in the SCSI Target.
|
|
func (cli *Client) LuCreate(ctx context.Context, options api.LuCreateRequest) error {
|
|
resp, err := cli.post(ctx, "/lu/create", nil, options, nil)
|
|
ensureReaderClosed(resp)
|
|
return err
|
|
}
|