diff --git a/.gitignore b/.gitignore index 47e5a62..a459b8e 100644 --- a/.gitignore +++ b/.gitignore @@ -65,6 +65,9 @@ Temporary Items *.env .env* +# Allow environment templates to be committed +!**/example.env + .idea # dependencies diff --git a/postgres/example.env b/postgres/example.env new file mode 100644 index 0000000..2ac7c40 --- /dev/null +++ b/postgres/example.env @@ -0,0 +1,3 @@ +POSTGRES_USER=root +POSTGRES_PASSWORD=secret +POSTGRES_DB=sc_db diff --git a/sc-api-getaway/example.env b/sc-api-getaway/example.env new file mode 100644 index 0000000..9186b94 --- /dev/null +++ b/sc-api-getaway/example.env @@ -0,0 +1,5 @@ +ENV_TYPE=development +SERVER_PORT=8000 +DB_SOURCE=postgresql://root:secret@localhost:5432/sc_db?sslmode=disable +GRPC_AUTH_PORT=localhost:50051 +WEBAPP_BASE_URL=http://localhost:3000 diff --git a/sc-auth/example.env b/sc-auth/example.env new file mode 100644 index 0000000..74ea4f0 --- /dev/null +++ b/sc-auth/example.env @@ -0,0 +1,3 @@ +ENV_TYPE=development +SERVER_PORT=50051 +DB_SOURCE=postgresql://root:secret@localhost:5432/sc_db?sslmode=disable diff --git a/sc-kafka/example.env b/sc-kafka/example.env new file mode 100644 index 0000000..6c6a286 --- /dev/null +++ b/sc-kafka/example.env @@ -0,0 +1,22 @@ +KAFKA_CONFIG_PATH=. +KAFKA_BROKERS=kafka-broker:9092 +KAFKA_CLIENT_ID=sc-kafka +KAFKA_DIAL_TIMEOUT=5s +KAFKA_READ_TIMEOUT=10s +KAFKA_WRITE_TIMEOUT=10s +KAFKA_TOPIC_POST_CREATED=post.created +KAFKA_TOPIC_SUBSCRIPTION_CREATED=subscription.created +KAFKA_TOPIC_NOTIFICATION=notification.created +KAFKA_PRODUCER_BATCH_SIZE=100 +KAFKA_PRODUCER_BATCH_TIMEOUT=200ms +KAFKA_PRODUCER_AUTO_CREATE_TOPIC=true +KAFKA_CONSUMER_POST_CREATED_GROUP=sc-post-consumers +KAFKA_CONSUMER_SUBSCRIPTION_GROUP=sc-subscription-consumers +KAFKA_CONSUMER_NOTIFICATION_GROUP=sc-notification-consumers +KAFKA_CONSUMER_MIN_BYTES=1 +KAFKA_CONSUMER_MAX_BYTES=10485760 +KAFKA_CONSUMER_COMMIT_INTERVAL=1s +KAFKA_CONSUMER_HEARTBEAT_INTERVAL=3s +KAFKA_CONSUMER_SESSION_TIMEOUT=30s +KAFKA_USERNAME= +KAFKA_PASSWORD= diff --git a/sc-notification/example.env b/sc-notification/example.env new file mode 100644 index 0000000..50b4f4c --- /dev/null +++ b/sc-notification/example.env @@ -0,0 +1,7 @@ +ENV_TYPE=development +SERVER_PORT=8080 +WEBAPP_BASE_URL=http://localhost:3000 +DB_SOURCE=postgresql://root:secret@localhost:5432/sc_db?sslmode=disable +KAFKA_BROKERS=localhost:9092 +KAFKA_NOTIFICATIONS_TOPIC=notification.created +KAFKA_GROUP_ID=sc-notification-consumers diff --git a/sc-post/example.env b/sc-post/example.env new file mode 100644 index 0000000..5885945 --- /dev/null +++ b/sc-post/example.env @@ -0,0 +1,6 @@ +ENV_TYPE=development +SERVER_PORT=50052 +WEBAPP_BASE_URL=http://localhost:3000 +DB_SOURCE=postgresql://root:secret@localhost:5432/sc_db?sslmode=disable +KAFKA_BROKERS=localhost:9092 +POST_EVENTS_TOPIC=post.created diff --git a/sc-user/example.env b/sc-user/example.env new file mode 100644 index 0000000..8b3fb03 --- /dev/null +++ b/sc-user/example.env @@ -0,0 +1,4 @@ +ENV_TYPE=development +SERVER_PORT=50053 +WEBAPP_BASE_URL=http://localhost:3000 +DB_SOURCE=postgresql://root:secret@localhost:5432/sc_db?sslmode=disable diff --git a/sc-webapp/example.env b/sc-webapp/example.env new file mode 100644 index 0000000..49ffa03 --- /dev/null +++ b/sc-webapp/example.env @@ -0,0 +1 @@ +REACT_APP_API_URL=http://localhost:8000