This is an simple example of project using go plugin lib
You need Make installed in your machine.
To build and run in one shot run: make start
To build and run separately:
- Run
make build
- Run
make run
Build using go build:
go build -buildmode=plugin -o ./plugins/plugin-a/ ./plugins/plugin-a/main.go
go build -buildmode=plugin -o ./plugins/plugin-b/ ./plugins/plugin-b/main.go
Run using go run:
go run app/main.go