Skip to content

Commit

Permalink
Update docker compose references to support working in CI and python3 (
Browse files Browse the repository at this point in the history
  • Loading branch information
unlikelyzero authored Oct 25, 2022
1 parent e0d3fbf commit 5df08c2
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 5 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,6 @@

# Maven output
/target/

# VSCode
.vscode/settings.json
8 changes: 7 additions & 1 deletion docker/Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
ifeq ($(shell which python3),)
PYTHON = python
else
PYTHON = python3
endif

.DEFAULT_GOAL := help

all: ## run all, yamcs-up (yamcs-down) and yamcs-simulator
Expand All @@ -11,7 +17,7 @@ yamcs-down: ## bring down yamcs system

yamcs-simulator: yamcs-up ## run yamcs simulator
@echo "connect via http://localhost:8090/ system make take about 50 seconds to startup" && \
cd .. && python ./simulator.py
cd .. && $(PYTHON) ./simulator.py

yamcs-shell: ## shell into yamcs container
docker-compose up -d && docker run -it yamcs "bash"
Expand Down
17 changes: 15 additions & 2 deletions docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,21 @@ services:
hostname: yamcs
container_name: yamcs
command: "mvn yamcs:run"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8090"]
interval: 10s
timeout: 5s
retries: 30
start_period: 30s
volumes:
- ../:/yamcs
ports:
- "127.0.0.1:8090:8090"
- "127.0.0.1:10015:10015/udp"
- "8090:8090"
- "10015:10015/udp"
extra_hosts:
- "host.docker.internal:host-gateway"
networks:
- quickstart
networks:
quickstart:
driver: bridge
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
Update this to the latest Yamcs release.
Check https://mvnrepository.com/artifact/org.yamcs/yamcs-core
-->
<yamcsVersion>5.7.7</yamcsVersion>
<yamcsVersion>5.7.8</yamcsVersion>
</properties>

<dependencies>
Expand Down
8 changes: 7 additions & 1 deletion src/main/yamcs/etc/yamcs.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
services:
- class: org.yamcs.http.HttpServer
args:
port: 8090
address: "0.0.0.0" # https://github.com/yamcs/quickstart/issues/11
cors:
allowOrigin: "*"
allowCredentials: false

# This is where Yamcs will persist its data. Paths are resolved relative to where Yamcs is running
# from (by default: target/yamcs). This means that `mvn clean` will remove also persisted data.
Expand All @@ -11,4 +17,4 @@ instances:

# Secret key unique to a particular Yamcs installation.
# This is used to provide cryptographic signing.
secretKey: changeme
secretKey: changeme

0 comments on commit 5df08c2

Please sign in to comment.