Skip to content

Commit

Permalink
added docker-compose.proto.yaml
Browse files Browse the repository at this point in the history
updated script file
updated Makefile
  • Loading branch information
riticksingh committed Nov 17, 2020
1 parent 09a405a commit 3444fb9
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 34 deletions.
4 changes: 1 addition & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,4 @@ vendor
coverage.clover
tests/coverage
.php_cs.cache
proto/*
opentelemetry-proto/*
grpc/*
proto/*
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ metrics-prometheus-example:
@docker-compose -f docker-compose.prometheus.yaml run php-prometheus php /var/www/public/examples/prometheus/PrometheusMetricsExample.php
stop-prometheus:
@docker-compose -f docker-compose.prometheus.yaml stop
proto:
@docker-compose -f docker-compose.proto.yaml up proto
bash:
$(DC_RUN_PHP) bash
style:
Expand Down
7 changes: 7 additions & 0 deletions docker-compose.proto.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
version: '3.7'
services:
proto:
image: socialpoint/protobuf-tools
volumes:
- ../:/mnt
command: sh -c "/mnt/script/proto_gen.sh"
6 changes: 6 additions & 0 deletions script/proto_gen.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
apk update && apk add git

mkdir /mnt/proto
git clone https://github.com/open-telemetry/opentelemetry-proto

protoc --proto_path=opentelemetry-proto/ --php_out=/mnt/proto --grpc_out=/mnt/proto --plugin=protoc-gen-grpc=usr/local/bin/grpc_php_plugin $(find opentelemetry-proto/opentelemetry -iname "*.proto")
31 changes: 0 additions & 31 deletions script/proto_generate.sh

This file was deleted.

0 comments on commit 3444fb9

Please sign in to comment.