Skip to content

Commit 704a112

Browse files
authored
Rename default config file to router.config (#493)
It's easier and is similar to what Hive Gateway does `gateway.config.ts`.
1 parent dbb0a81 commit 704a112

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
A fully open-source MIT-licensed GraphQL API router that can act as a [GraphQL federation](https://the-guild.dev/graphql/hive/federation) Router, built with Rust for maximum performance and robustness.
66

77
> [!TIP]
8-
> 🚀 [Blog post: Welcome Hive Router](https://the-guild.dev/graphql/hive/blog/welcome-hive-router)
9-
>
8+
> 🚀 [Blog post: Welcome Hive Router](https://the-guild.dev/graphql/hive/blog/welcome-hive-router)
9+
>
1010
> Interested in the benchmark results? Check out the [Federation Gateway Performance comparison](https://the-guild.dev/graphql/hive/federation-gateway-performance)
1111
1212
It can be run as a standalone binary or a Docker Image. Query planner can be used as a standalone Crate library.
@@ -26,7 +26,7 @@ curl -o- https://raw.githubusercontent.com/graphql-hive/router/main/install.sh |
2626
Create a simple configuration file that points to your supergraph schema file:
2727

2828
```yaml
29-
# hive-router.config.yaml
29+
# router.config.yaml
3030
supergraph:
3131
source: file
3232
path: ./supergraph.graphql
@@ -42,7 +42,7 @@ HIVE__SUPERGRAPH__PATH=./supergraph.graphql
4242
Then, run the router:
4343

4444
```bash
45-
# By default, "hive-router.config.yaml" is used for configuration. Override it by setting "ROUTER_CONFIG_FILE_PATH=some-custom-file.yaml"
45+
# By default, "router.config.yaml" is used for configuration. Override it by setting "ROUTER_CONFIG_FILE_PATH=some-custom-file.yaml"
4646
# If you are using env vars, make sure to set the variables before running the router.
4747
./hive_router
4848
```
@@ -71,7 +71,7 @@ Alternativly, you can mount the configuration file using `-v` and pass all other
7171
```bash
7272
docker run \
7373
-p 4000:4000 \
74-
-v ./hive-router.config.yaml:/app/hive-router.config.yaml \
74+
-v ./router.config.yaml:/app/router.config.yaml \
7575
ghcr.io/graphql-hive/router:latest
7676
```
7777

lib/router-config/src/lib.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -78,10 +78,10 @@ pub enum RouterConfigError {
7878
}
7979

8080
static DEFAULT_FILE_NAMES: &[&str] = &[
81-
"hive-router.config.yaml",
82-
"hive-router.config.yml",
83-
"hive-router.config.json",
84-
"hive-router.config.json5",
81+
"router.config.yaml",
82+
"router.config.yml",
83+
"router.config.json",
84+
"router.config.json5",
8585
];
8686

8787
pub fn load_config(

0 commit comments

Comments
 (0)