Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
mysql_data_source_name:"fleetspeak-user:fleetspeak-password@tcp(mysql-server:3306)/fleetspeak"
mysql_data_source_name:"fleetspeak-user:FS_PASSWORD@tcp(mysql-server:3306)/fleetspeak"
https_config: {
listen_address: "0.0.0.0:9090"
certificates:"FRONTEND_CERTIFICATE"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ configuration_name: "Example"

components_config {

mysql_data_source_name: "fleetspeak-user:fleetspeak-password@tcp(mysql-server:3306)/fleetspeak"
mysql_data_source_name: "fleetspeak-user:FS_PASSWORD@tcp(mysql-server:3306)/fleetspeak"

https_config {
listen_address: "fleetspeak-server:9090"
Expand Down
12 changes: 5 additions & 7 deletions sandboxes/cleartext-header-mode/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ services:
environment:
MYSQL_DATABASE: 'fleetspeak'
MYSQL_USER: 'fleetspeak-user'
MYSQL_PASSWORD: 'fleetspeak-password'
MYSQL_ROOT_PASSWORD: 'password'
MYSQL_PASSWORD: 'FS_PASSWORD'
MYSQL_ROOT_PASSWORD: 'FS_SQL_PASSWORD'
ports:
- '3306:3306'
expose:
Expand All @@ -29,14 +29,12 @@ services:
- "10000:10000"

fleetspeak-server:
build:
context: .
dockerfile: ../shared/fleetspeak-server/Dockerfile
image: ghcr.io/google/fleetspeak:latest
hostname: fleetspeak-server
depends_on:
mysql-server:
condition: service_healthy
entrypoint: ["/app/bin/server", "-components_config", "/config/fleetspeak-server/components.textproto", "-services_config", "/config/fleetspeak-server/services.textproto", "-alsologtostderr"]
entrypoint: ["/fleetspeak/bin/server", "-components_config", "/config/fleetspeak-server/components.textproto", "-services_config", "/config/fleetspeak-server/services.textproto", "-alsologtostderr"]
volumes:
- "./config:/config"
ports:
Expand All @@ -60,6 +58,6 @@ services:
depends_on:
fleetspeak-server:
condition: service_healthy
entrypoint: ["/app/bin/client", "-config", "/config/fleetspeak-client/config.textproto", "-alsologtostderr"]
entrypoint: ["/fleetspeak/bin/client", "-config", "/config/fleetspeak-client/config.textproto", "-alsologtostderr"]
volumes:
- "./config:/config"
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
mysql_data_source_name:"fleetspeak-user:fleetspeak-password@tcp(mysql-server:3306)/fleetspeak"
mysql_data_source_name:"fleetspeak-user:FS_PASSWORD@tcp(mysql-server:3306)/fleetspeak"
https_config: {
listen_address: "0.0.0.0:9090"
certificates:"FRONTEND_CERTIFICATE"
Expand Down
2 changes: 1 addition & 1 deletion sandboxes/cleartext-xfcc-mode/config/fleetspeak.textproto
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ configuration_name: "Example"

components_config {

mysql_data_source_name: "fleetspeak-user:fleetspeak-password@tcp(mysql-server:3306)/fleetspeak"
mysql_data_source_name: "fleetspeak-user:FS_PASSWORD@tcp(mysql-server:3306)/fleetspeak"

https_config {
listen_address: "fleetspeak-server:9090"
Expand Down
4 changes: 2 additions & 2 deletions sandboxes/cleartext-xfcc-mode/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ services:
environment:
MYSQL_DATABASE: 'fleetspeak'
MYSQL_USER: 'fleetspeak-user'
MYSQL_PASSWORD: 'fleetspeak-password'
MYSQL_ROOT_PASSWORD: 'password'
MYSQL_PASSWORD: 'FS_PASSWORD'
MYSQL_ROOT_PASSWORD: 'FS_SQL_PASSWORD'
ports:
- '3306:3306'
expose:
Expand Down
27 changes: 27 additions & 0 deletions sandboxes/createConfig.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,30 @@ cp cert.pem key.pem ./cleartext-xfcc-mode/
cp cert.pem key.pem ./direct-mtls-mode/
cp cert.pem key.pem ./https-header-mode/
cp cert.pem key.pem ./passthrough-mode/

MYSQL_PASSWORD=$(LC_ALL=C tr -dc 'A-Za-z0-9@%*+,-./' < /dev/urandom 2>/dev/null | head -c 16)
FLEETSPEAK_PASSWORD=$(LC_ALL=C tr -dc 'A-Za-z0-9@%*+,-./' < /dev/urandom 2>/dev/null | head -c 16)

sed -i 's@FS_SQL_PASSWORD@'"$MYSQL_PASSWORD"'@' ./cleartext-header-mode/docker-compose.yaml
sed -i 's@FS_SQL_PASSWORD@'"$MYSQL_PASSWORD"'@' ./cleartext-xfcc-mode/docker-compose.yaml
sed -i 's@FS_SQL_PASSWORD@'"$MYSQL_PASSWORD"'@' ./direct-mtls-mode/docker-compose.yaml
sed -i 's@FS_SQL_PASSWORD@'"$MYSQL_PASSWORD"'@' ./https-header-mode/docker-compose.yaml
sed -i 's@FS_SQL_PASSWORD@'"$MYSQL_PASSWORD"'@' ./passthrough-mode/docker-compose.yaml

sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./cleartext-header-mode/docker-compose.yaml
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./cleartext-xfcc-mode/docker-compose.yaml
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./direct-mtls-mode/docker-compose.yaml
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./https-header-mode/docker-compose.yaml
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./passthrough-mode/docker-compose.yaml

sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./cleartext-header-mode/config/fleetspeak-server/components.textproto
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./cleartext-xfcc-mode/config/fleetspeak-server/components.textproto
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./direct-mtls-mode/config/fleetspeak-server/components.textproto
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./https-header-mode/config/fleetspeak-server/components.textproto
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./passthrough-mode/config/fleetspeak-server/components.textproto

sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./cleartext-header-mode/config/fleetspeak.textproto
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./cleartext-xfcc-mode/config/fleetspeak.textproto
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./direct-mtls-mode/config/fleetspeak.textproto
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./https-header-mode/config/fleetspeak.textproto
sed -i 's@FS_PASSWORD@'"$FLEETSPEAK_PASSWORD"'@' ./passthrough-mode/config/fleetspeak.textproto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
mysql_data_source_name:"fleetspeak-user:fleetspeak-password@tcp(mysql-server:3306)/fleetspeak"
mysql_data_source_name:"fleetspeak-user:FS_PASSWORD@tcp(mysql-server:3306)/fleetspeak"
https_config: {
listen_address: "0.0.0.0:9090"
certificates:"FRONTEND_CERTIFICATE"
Expand Down
2 changes: 1 addition & 1 deletion sandboxes/direct-mtls-mode/config/fleetspeak.textproto
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ configuration_name: "Example"

components_config {

mysql_data_source_name: "fleetspeak-user:fleetspeak-password@tcp(mysql-server:3306)/fleetspeak"
mysql_data_source_name: "fleetspeak-user:FS_PASSWORD@tcp(mysql-server:3306)/fleetspeak"

https_config {
listen_address: "fleetspeak-server:9090"
Expand Down
4 changes: 2 additions & 2 deletions sandboxes/direct-mtls-mode/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ services:
environment:
MYSQL_DATABASE: 'fleetspeak'
MYSQL_USER: 'fleetspeak-user'
MYSQL_PASSWORD: 'fleetspeak-password'
MYSQL_ROOT_PASSWORD: 'password'
MYSQL_PASSWORD: 'FS_PASSWORD'
MYSQL_ROOT_PASSWORD: 'FS_SQL_PASSWORD'
ports:
- '3306:3306'
expose:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
mysql_data_source_name:"fleetspeak-user:fleetspeak-password@tcp(mysql-server:3306)/fleetspeak"
mysql_data_source_name:"fleetspeak-user:FS_PASSWORD@tcp(mysql-server:3306)/fleetspeak"
https_config: {
listen_address: "0.0.0.0:9090"
certificates:"FRONTEND_CERTIFICATE"
Expand Down
2 changes: 1 addition & 1 deletion sandboxes/https-header-mode/config/fleetspeak.textproto
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ configuration_name: "Example"

components_config {

mysql_data_source_name: "fleetspeak-user:fleetspeak-password@tcp(mysql-server:3306)/fleetspeak"
mysql_data_source_name: "fleetspeak-user:FS_PASSWORD@tcp(mysql-server:3306)/fleetspeak"

https_config {
listen_address: "fleetspeak-server:9090"
Expand Down
4 changes: 2 additions & 2 deletions sandboxes/https-header-mode/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ services:
environment:
MYSQL_DATABASE: 'fleetspeak'
MYSQL_USER: 'fleetspeak-user'
MYSQL_PASSWORD: 'fleetspeak-password'
MYSQL_ROOT_PASSWORD: 'password'
MYSQL_PASSWORD: 'FS_PASSWORD'
MYSQL_ROOT_PASSWORD: 'FS_SQL_PASSWORD'
ports:
- '3306:3306'
expose:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
mysql_data_source_name:"fleetspeak-user:fleetspeak-password@tcp(mysql-server:3306)/fleetspeak"
mysql_data_source_name:"fleetspeak-user:FS_PASSWORD@tcp(mysql-server:3306)/fleetspeak"
https_config: {
listen_address: "0.0.0.0:9090"
certificates:"FRONTEND_CERTIFICATE"
Expand Down
2 changes: 1 addition & 1 deletion sandboxes/passthrough-mode/config/fleetspeak.textproto
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ configuration_name: "Example"

components_config {

mysql_data_source_name: "fleetspeak-user:fleetspeak-password@tcp(mysql-server:3306)/fleetspeak"
mysql_data_source_name: "fleetspeak-user:FS_PASSWORD@tcp(mysql-server:3306)/fleetspeak"

https_config {
listen_address: "fleetspeak-server:9090"
Expand Down
4 changes: 2 additions & 2 deletions sandboxes/passthrough-mode/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ services:
environment:
MYSQL_DATABASE: 'fleetspeak'
MYSQL_USER: 'fleetspeak-user'
MYSQL_PASSWORD: 'fleetspeak-password'
MYSQL_ROOT_PASSWORD: 'password'
MYSQL_PASSWORD: 'FS_PASSWORD'
MYSQL_ROOT_PASSWORD: 'FS_SQL_PASSWORD'
ports:
- '3306:3306'
expose:
Expand Down
2 changes: 1 addition & 1 deletion sandboxes/shared/envoy/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ ARG ENVOY_IMAGE="${ENVOY_IMAGE:-envoyproxy/envoy}"
ARG ENVOY_VARIANT="${ENVOY_VARIANT:-dev}"


FROM ${ENVOY_IMAGE}:${ENVOY_VARIANT} as envoy-base
FROM ${ENVOY_IMAGE}:${ENVOY_VARIANT} AS envoy-base
ARG ENVOY_CONFIG=envoy.yaml
ENV ENVOY_CONFIG="$ENVOY_CONFIG"
ENV DEBIAN_FRONTEND=noninteractive
Expand Down
Loading