sha256:f22c7d5e9d784c051618dd5ae2b75a2c8132cefffe0c9aaed666a0ae8f1ab702
Last pushed
6 days by saikrishnabairamoni
Type
Compose
Manifest digest
sha256:f22c7d5e9d784c051618dd5ae2b75a2c8132cefffe0c9aaed666a0ae8f1ab702
services:
db:
image: mysql:8.0.40
environment:
- TZ=${TZ:-America/New_York}
- MYSQL_DATABASE=IVP
- MYSQL_USER=IVP
- MYSQL_PASSWORD_FILE=/run/secrets/mysql_password
- MYSQL_RANDOM_ROOT_PASSWORD=yes
networks:
- v2xhub_data_internal
secrets:
- mysql_password
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "db", "-u", "IVP", "-p$$(cat /run/secrets/mysql_password)"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
volumes:
- ${INIT_DB:-./mysql}:/docker-entrypoint-initdb.d
# The following 5 files are used for CDA1Tenth. By default the standard "port_drayage.sql" file
# will be loaded. Comment out the "port_drayage.sql" file above and uncomment the following
# three files to enable the CDA1Tenth sql files to be loaded.
#- ./mysql/garage_port_drayage/port_drayage.sql:/docker-entrypoint-initdb.d/port_drayage.sql
#- ./mysql/garage_port_drayage/port_drayage_lane1.sql:/docker-entrypoint-initdb.d/port_drayage_lane1.sql
#- ./mysql/garage_port_drayage/port_drayage_lane2.sql:/docker-entrypoint-initdb.d/port_drayage_lane2.sql
#- ./mysql/garage_port_drayage/port_drayage_trb_short.sql:/docker-entrypoint-initdb.d/port_drayage_trb_short.sql
#- ./mysql/garage_port_drayage/port_drayage_trb_long.sql:/docker-entrypoint-initdb.d/port_drayage_trb_long.sql
- mysql-datavolume:/var/lib/mysql
php:
image: usdotfhwaops/php:${V2XHUB_VERSION:-develop}
networks:
- v2xhub_web_external
ports:
- target: 80
published: ${PHP_HTTP_EXTERNAL_PORT:-80}
- target: 443
published: ${PHP_HTTPS_EXTERNAL_PORT:-443}
restart: always
depends_on:
- db
- v2xhub
stdin_open: true
tty: true
environment:
- TZ=${TZ:-America/New_York}
volumes:
- ssl-certs-volume:/etc/apache2/ssl:ro
healthcheck:
test: ["CMD-SHELL", "curl -fsS -I http://127.0.0.1/ >/dev/null || exit 1"]
interval: 10s
timeout: 5s
retries: 12
start_period: 30s
v2xhub:
image: usdotfhwaops/v2xhub:${V2XHUB_VERSION:-develop}
networks:
- v2xhub_data_internal
- v2xhub_app_external
ports:
# Command Plugin Websocket
- target: 19760
published: ${COMMAND_PLUGIN_EXTERNAL_PORT:-19760}
# Message Receiver Plugin
- target: 26789
published: ${MESSAGE_RECEIVER_PLUGIN_EXTERNAL_PORT:-26789}
protocol: udp
# SPaT Plugin
- target: 6053
published: ${SPAT_PLUGIN_EXTERNAL_PORT:-6053}
protocol: udp
# TIM Plugin
- target: 10000
published: ${TIM_PLUGIN_EXTERNAL_PORT:-10000}
# CARMA Cloud Plugin
- target: 22222
published: ${CARMA_CLOUD_EXTERNAL_PORT:-22222}
# CDASim Adapter Plugin (simulation mode)
- target: 6767
published: ${CDASIM_ADAPTER_PLUGIN_EXTERNAL_REGISTRATION_PORT:-6767} # CDASim registration
protocol: udp
- target: 7575
published: ${CDASIM_ADAPTER_PLUGIN_EXTERNAL_TIMESYNC_PORT:-7575} # CDASim Time Sync
protocol: udp
- target: 5757
published: ${CDASIM_ADAPTER_PLUGIN_EXTERNAL_V2X_PORT:-5757} # CDASim Simulated V2X Messages
protocol: udp
# MUST Sensor Driver Plugin
- target: 4545
published: ${MUST_SENSOR_PLUGIN_EXTERNAL_PORT:-4545}
protocol: udp
extra_hosts:
- "host.docker.internal:host-gateway"
restart: always
depends_on:
db:
condition: service_healthy
ulimits:
nofile:
soft: 2560
hard: 2560
deploy:
resources:
limits:
memory: 2g
reservations:
memory: 1g
environment:
- MYSQL_HOST=db
- MYSQL_PORT=3306
- MYSQL_DATABASE=IVP
- MYSQL_USER=IVP
- MYSQL_PASSWORD=/run/secrets/mysql_password
- SIMULATION_MODE=${SIMULATION_MODE:-false}
- SIMULATION_IP=${SIMULATION_IP:-127.0.0.1}
- SIMULATION_REGISTRATION_PORT=6767
- V2XHUB_IP=${V2XHUB_IP:-0.0.0.0}
- TIME_SYNC_TOPIC=time_sync
- TIME_SYNC_PORT=7575
- SIM_V2X_PORT=5757
- SIM_INTERACTION_PORT=7576
- V2X_PORT=8686
- INFRASTRUCTURE_ID=${INFRASTRUCTURE_ID:-rsu_1234}
- INFRASTRUCTURE_NAME=${INFRASTRUCTURE_NAME:-East Intersection}
- SENSOR_JSON_FILE_PATH=${SENSOR_JSON_FILE_PATH:-/var/www/download/sensors.json}
- V2XHUB_USERNAME=${V2XHUB_USERNAME:-v2xadmin}
- V2XHUB_PASSWORD=${V2XHUB_PASSWORD}
- TZ=${TZ:-America/New_York}
secrets:
- mysql_password
volumes:
- v2xhub-logs-volume:/var/log/tmx:rw
- v2xhub-download-volume:/var/www/download/:rw
- ssl-certs-volume:/var/www/plugins/ssl:rw
healthcheck:
test: ["CMD-SHELL", "ps -ef | grep -v grep | grep -q tmxcore && ps -ef | grep -v grep | grep -q CommandPlugin || exit 1"]
interval: 10s
timeout: 5s
retries: 12
start_period: 30s
port_drayage_webservice:
image: usdotfhwaops/port-drayage-webservice:${V2XHUB_VERSION:-develop}
networks:
- v2xhub_web_external
ports:
- target: 8090
published: ${PORT_DRAYAGE_SERVICE_EXTERNAL_PORT:-8090} # Port Drayage web UI
profiles: ["port_drayage"]
deploy:
resources:
limits:
memory: 1g
reservations:
memory: 512m
environment:
- TZ=${TZ:-America/New_York}
secrets:
mysql_password:
environment: MYSQL_PASSWORD
volumes:
mysql-datavolume:
ssl-certs-volume:
# To access/set SSL certifications on host machine setup local mapping to ssl directory.
# NOTE: Ensure directory exists and has non-root privileges before running
# docker compose to prevent permission issues
driver: local
driver_opts:
type: 'none'
o: 'bind'
device: '${V2XHUB_VOLUME_PATH:-/tmp/v2xhub_data}/ssl' # Specify the absolute path on your host
v2xhub-download-volume:
# To access V2X Hub uploaded files on host machine setup local mapping to download directory.
# NOTE: Ensure directory exists and has non-root privileges before running
# docker compose to prevent permission issues
driver: local
driver_opts:
type: 'none'
o: 'bind'
device: '${V2XHUB_VOLUME_PATH:-/tmp/v2xhub_data}/download' # Specify the absolute path on your host
v2xhub-logs-volume:
# To access log files on host machine setup local mapping to logs directory.
# NOTE: Ensure directory exists and has non-root privileges before running
# docker compose to prevent permission issues
driver: local
driver_opts:
type: 'none'
o: 'bind'
device: '${V2XHUB_VOLUME_PATH:-/tmp/v2xhub_data}/logs' # Specify the absolute path on your host
# Networks: separated by purpose
networks:
v2xhub_web_external:
driver: bridge
v2xhub_app_external:
driver: bridge
v2xhub_data_internal:
driver: bridge
internal: true # No external internet access - only inter-service communication
docker compose -f oci://usdotfhwaops/v2xhub-application:develop upUse the above command to pull and run the Compose file. Learn more.
MySQL is a widely used, open-source relational database management system (RDBMS).
Pulls
1B+
Stars
16189
Last Updated
9 days