From 208253b3096fcc53ee2b0c9b94cc5ceee3e451de Mon Sep 17 00:00:00 2001 From: roekatz Date: Wed, 10 Jul 2024 19:45:41 +0300 Subject: [PATCH] Fix opal-server addr to opal-server rather than host.docker.internal --- docker/docker-compose-api-policy-source-example.yml | 2 +- docker/docker-compose-with-callbacks.yml | 2 +- docker/docker-compose-with-kafka-example.yml | 2 +- docker/docker-compose-with-rate-limiting.yml | 2 +- docker/docker-compose-with-security.yml | 2 +- docker/docker-compose-with-statistics.yml | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docker/docker-compose-api-policy-source-example.yml b/docker/docker-compose-api-policy-source-example.yml index 466689a5a..a91997e4e 100644 --- a/docker/docker-compose-api-policy-source-example.yml +++ b/docker/docker-compose-api-policy-source-example.yml @@ -37,7 +37,7 @@ services: # configures from where the opal client should initially fetch data (when it first goes up, after disconnection, etc). # the data sources represents from where the opal clients should get a "complete picture" of the data they need. # after the initial sources are fetched, the client will subscribe only to update notifications sent by the server. - - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://host.docker.internal:7002/policy-data","topics":["policy_data"],"dst_path":"/static"}]}} + - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://opal-server:7002/policy-data","topics":["policy_data"],"dst_path":"/static"}]}} - OPAL_LOG_FORMAT_INCLUDE_PID=true ports: # exposes opal server on the host machine, you can access the server at: http://localhost:7002 diff --git a/docker/docker-compose-with-callbacks.yml b/docker/docker-compose-with-callbacks.yml index 7ce3eacce..b47e39bcb 100644 --- a/docker/docker-compose-with-callbacks.yml +++ b/docker/docker-compose-with-callbacks.yml @@ -32,7 +32,7 @@ services: # configures from where the opal client should initially fetch data (when it first goes up, after disconnection, etc). # the data sources represents from where the opal clients should get a "complete picture" of the data they need. # after the initial sources are fetched, the client will subscribe only to update notifications sent by the server. - - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://host.docker.internal:7002/policy-data","topics":["policy_data"],"dst_path":"/static"}]}} + - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://opal_server:7002/policy-data","topics":["policy_data"],"dst_path":"/static"}]}} - OPAL_LOG_FORMAT_INCLUDE_PID=true ports: # exposes opal server on the host machine, you can access the server at: http://localhost:7002 diff --git a/docker/docker-compose-with-kafka-example.yml b/docker/docker-compose-with-kafka-example.yml index 99b4129c7..ec4f113e2 100644 --- a/docker/docker-compose-with-kafka-example.yml +++ b/docker/docker-compose-with-kafka-example.yml @@ -70,7 +70,7 @@ services: # configures from where the opal client should initially fetch data (when it first goes up, after disconnection, etc). # the data sources represents from where the opal clients should get a "complete picture" of the data they need. # after the initial sources are fetched, the client will subscribe only to update notifications sent by the server. - - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://host.docker.internal:7002/policy-data","topics":["policy_data"],"dst_path":"/static"}]}} + - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://opal-server:7002/policy-data","topics":["policy_data"],"dst_path":"/static"}]}} - OPAL_LOG_FORMAT_INCLUDE_PID=true ports: # exposes opal server on the host machine, you can access the server at: http://localhost:7002 diff --git a/docker/docker-compose-with-rate-limiting.yml b/docker/docker-compose-with-rate-limiting.yml index a0fd3bbcc..b5fb169b4 100644 --- a/docker/docker-compose-with-rate-limiting.yml +++ b/docker/docker-compose-with-rate-limiting.yml @@ -31,7 +31,7 @@ services: # configures from where the opal client should initially fetch data (when it first goes up, after disconnection, etc). # the data sources represents from where the opal clients should get a "complete picture" of the data they need. # after the initial sources are fetched, the client will subscribe only to update notifications sent by the server. - - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://host.docker.internal:7002/policy-data","topics":["policy_data"],"dst_path":"/static"}]}} + - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://opal-server:7002/policy-data","topics":["policy_data"],"dst_path":"/static"}]}} - OPAL_LOG_FORMAT_INCLUDE_PID=true # Turns on rate limiting in the server # supported formats documented here: https://limits.readthedocs.io/en/stable/quickstart.html#rate-limit-string-notation diff --git a/docker/docker-compose-with-security.yml b/docker/docker-compose-with-security.yml index 8a80ad2a6..ad3ae6186 100644 --- a/docker/docker-compose-with-security.yml +++ b/docker/docker-compose-with-security.yml @@ -46,7 +46,7 @@ services: # after the initial sources are fetched, the client will subscribe only to update notifications sent by the server. # please notice - since we fetch data entries from the OPAL server itself, we need to authenticate to that endpoint # with the client's token (JWT). - - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://host.docker.internal:7002/policy-data","config":{"headers":{"Authorization":"Bearer ${OPAL_CLIENT_TOKEN}"}},"topics":["policy_data"],"dst_path":"/static"}]}} + - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://opal-server:7002/policy-data","config":{"headers":{"Authorization":"Bearer ${OPAL_CLIENT_TOKEN}"}},"topics":["policy_data"],"dst_path":"/static"}]}} - OPAL_LOG_FORMAT_INCLUDE_PID=true # -------------------------------------------------------------------------------- # the jwt audience and jwt issuer are not typically necessary in real setups diff --git a/docker/docker-compose-with-statistics.yml b/docker/docker-compose-with-statistics.yml index 0c15d5a95..daf10fa02 100644 --- a/docker/docker-compose-with-statistics.yml +++ b/docker/docker-compose-with-statistics.yml @@ -32,7 +32,7 @@ services: # configures from where the opal client should initially fetch data (when it first goes up, after disconnection, etc). # the data sources represents from where the opal clients should get a "complete picture" of the data they need. # after the initial sources are fetched, the client will subscribe only to update notifications sent by the server. - - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://host.docker.internal:7002/policy-data","topics":["policy_data"],"dst_path":"/static"}]}} + - OPAL_DATA_CONFIG_SOURCES={"config":{"entries":[{"url":"http://opal-server:7002/policy-data","topics":["policy_data"],"dst_path":"/static"}]}} - OPAL_LOG_FORMAT_INCLUDE_PID=true # turning on statistics collection on the server side - OPAL_STATISTICS_ENABLED=true