/*
   Copyright The containerd Authors.

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.
*/

syntax = "proto3";

option go_package = "github.com/stargz-snapshotter/fusemanager/api";

package fusemanager;

service StargzFuseManagerService {
    rpc Status (StatusRequest) returns (StatusResponse);
    rpc Init (InitRequest) returns (Response);
    rpc Mount (MountRequest) returns (Response);
    rpc Check (CheckRequest) returns (Response);
    rpc Unmount (UnmountRequest) returns (Response);
}

message StatusRequest {
}

message InitRequest {
    string root = 1;
    bytes config = 2;
}

message MountRequest {
    string mountpoint = 1;
    map<string, string> labels = 2;
}

message CheckRequest {
    string mountpoint = 1;
    map<string, string> labels = 2;
}

message UnmountRequest {
    string mountpoint = 1;
}

message StatusResponse {
    int32 status = 1;
}

message Response {
}