Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot run server #99

Closed
matsuyoido opened this issue Dec 6, 2021 · 1 comment
Closed

Cannot run server #99

matsuyoido opened this issue Dec 6, 2021 · 1 comment

Comments

@matsuyoido
Copy link

I tried run server on Docker, but exit status 1...

Can you identify the cause and fix it?

※ As a premise, filename and package name cannot be changed.

Directory

  • docker-compose.yml
  • proto/hoge-server.proto
  • proto/hoge-server-model.proto

File details

docker-compose.yml

version: '3.7'

services:
  gripmock:
    image: tkpd/gripmock:1.10.1
    command: /protp/hoge-server.proto
  volumes:
    - ./proto:/proto

proto/hoge-server.proto

syntax = "proto3";

package hoge.hoge_hello.v1;
option go_package = "hoge.hoge_hello.v1";

import "hoge-server-model.proto";

service Hoge {
  rpc Hello (HelloRequest) returns (HelloResponse);
}

message HelloRequest {
  Person person = 1;
}
message HelloResponse {
  string msg = 1;
}

proto/hoge-server-model.proto

syntax = "proto3";

package hoge.hoge_hello.v1;
option go_package = "hoge.hoge_hello.v1";

message Person {
  string name = 1;
}

Exec log( $ docker-compoe up )

2021/12/06 12:00:00 Failed to generate server formatting: 21:12: expected 'STRING', found '.' (and 2 more errors)
// Code generated by GripMock. DO NOT EDIT.
package main
...
import hoge.hoge_hello.v1 "hoge.hoge_hello.v1"
...

--gripmock_out: protoc-gen-gripmock: Plugin failed with status code 1.
2021/12/06 12:00:00 Failed on protoc exit status 1
exited with code 1
@jekiapp
Copy link
Contributor

jekiapp commented Jun 13, 2022

try to use image tkpd/gripmock:v1.11-beta and remove the option go_package = "hoge.hoge_hello.v1";

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants