Skip to content

Commit

Permalink
Merge branch 'nova' of https://github.com/RoboTeamTwente/roboteam int…
Browse files Browse the repository at this point in the history
…o nova
  • Loading branch information
aelhabashy committed Oct 29, 2024
2 parents 245a0aa + 7f94d86 commit f2e5b5a
Show file tree
Hide file tree
Showing 2 changed files with 75 additions and 183 deletions.
22 changes: 1 addition & 21 deletions docker/runner/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -223,24 +223,4 @@ services:
- ./ssl-game-controller-config:/config
- ./ssl-game-controller-data:/data
command: -address :8081
profiles: ["simulator","diff","game", "RL"]

simulator:
image: ${SUMATRA_IMAGE_SIMULATOR:-sumatra:latest}
command: "-hl --moduli sim_server --autoRef --maxSpeed --initialCommand PREPARE_KICKOFF_BLUE --waitForAis --playingTime ${SUMATRA_TARGET_STAGE_TIME:-0} --timeout ${SUMATRA_TIMEOUT:-0} ${SUMATRA_SIMULATOR_ADDITIONAL_ARGS:-}"
user: "${USER_ID:-1000}:${GROUP_ID:-1000}"
volumes:
- "./temp/${PROJECT_NAME}/simulator/build:/Sumatra/data"
- "./temp/${PROJECT_NAME}/simulator/data:/Sumatra/data"
networks:
- default
profiles: ["RL"]

ai-blue:
image: ${SUMATRA_IMAGE_BLUE:-sumatra:latest}
command: "-hl --moduli sim_client --host simulator --aiBlue ${SUMATRA_AI_ADDITIONAL_ARGS:-}"
user: "${USER_ID:-1000}:${GROUP_ID:-1000}"
environment:
- SUMATRA_INFLUX_DB_URL=${SUMATRA_INFLUX_DB_URL:-http://influxdb:8086}
- SUMATRA_INFLUX_DB_PASSWORD=${SUMATRA_INFLUX_DB_PASSWORD:-}
- SUMATRA_INFLUX_DB_USERNAME=${SUMATRA_INFLUX_DB_USERNAME:-}
profiles: ["simulator","diff","game", "RL"]
236 changes: 74 additions & 162 deletions docker/runner/kube.yaml
Original file line number Diff line number Diff line change
@@ -1,52 +1,3 @@
# ---
# apiVersion: v1
# kind: PersistentVolumeClaim
# metadata:
# name: roboteam-build-pvc
# spec:
# accessModes:
# - ReadWriteOnce
# resources:
# requests:
# storage: 1Gi

# ---
# apiVersion: v1
# kind: PersistentVolumeClaim
# metadata:
# name: roboteam-interface-pvc
# spec:
# accessModes:
# - ReadWriteOnce
# resources:
# requests:
# storage: 1Gi

# ---
# apiVersion: v1
# kind: PersistentVolumeClaim
# metadata:
# name: roboteam-autoref-pvc
# spec:
# accessModes:
# - ReadWriteOnce
# resources:
# requests:
# storage: 1Gi

# ---
# apiVersion: v1
# kind: PersistentVolumeClaim
# metadata:
# name: roboteam-root-pvc
# spec:
# accessModes:
# - ReadWriteOnce
# resources:
# requests:
# storage: 5Gi

---
apiVersion: apps/v1
kind: Deployment
metadata:
Expand All @@ -61,17 +12,11 @@ spec:
labels:
app: roboteam-simulator
spec:
hostNetwork: true
containers:
- name: ssl-game-controller
image: robocupssl/ssl-game-controller:latest
ports:
- containerPort: 8081
# volumeMounts:
# - name: ssl-game-controller-config
# mountPath: /config
# - name: ssl-game-controller-data
# mountPath: /data
image: robocupssl/ssl-game-controller:latest
resources:
requests:
cpu: 100m
Expand All @@ -83,12 +28,13 @@ spec:
- name: roboteam-primary-ai
image: roboteamtwente/roboteam:kubernetes
command: ["/bin/sh"]
args: ["-c", "/home/roboteamtwente/bin/roboteam_ai --primary-ai"]
args: ["-c", "/home/roboteam/build/release/bin/roboteam_ai --primary-ai"]
env:
- name: LD_LIBRARY_PATH
value: /home/roboteamtwente/lib
workingDir: /home/roboteamtwente

- name: LD_LIBRARY_PATH
value: "/home/roboteam/build/release/lib"
workingDir: /home/roboteam
ports:
- containerPort: 12676
resources:
requests:
cpu: 500m
Expand All @@ -97,31 +43,18 @@ spec:
cpu: 500m
memory: 1Gi

# volumeMounts:
# - name: roboteam-build
# mountPath: /home/roboteamtwente

# - name: roboteam-secondary-ai
# image: roboteamtwente/roboteam:kubernetes
# workingDir: "/home/roboteamtwente/"
# command: ["/bin/sh", "-c"]
# args: ["./bin/roboteam_ai --secondary-ai"]
# env:
# - name: LD_LIBRARY_PATH
# value: "/home/roboteamtwente/lib/"
# volumeMounts:
# - name: roboteam-build
# mountPath: /home/roboteamtwente

- name: roboteam-observer-sim
image: roboteamtwente/roboteam:kubernetes
command: ["/bin/sh"]
args: ["-c", "/home/roboteamtwente/bin/roboteam_observer --vision-ip 224.5.23.2 --referee-ip 224.5.23.1 --vision-port 10020 --referee-port 10003 --log"]
args: ["-c", "/home/roboteam/build/release/bin/roboteam_observer --vision-ip 127.0.0.1 --referee-ip 127.0.0.1 --vision-port 10020 --referee-port 10003 --log"]
env:
- name: LD_LIBRARY_PATH
value: /home/roboteamtwente/lib
workingDir: /home/roboteamtwente

- name: LD_LIBRARY_PATH
value: /home/roboteam/build/release/lib
workingDir: /home/roboteam
ports:
- containerPort: 10006
- containerPort: 10020
- containerPort: 10003
resources:
requests:
cpu: 500m
Expand All @@ -133,12 +66,18 @@ spec:
- name: roboteam-robothub-sim
image: roboteamtwente/roboteam:kubernetes
command: ["/bin/sh"]
args: ["-c", "/home/roboteamtwente/bin/roboteam_robothub"]
args: ["-c", "/home/roboteam/build/release/bin/roboteam_robothub"]
env:
- name: LD_LIBRARY_PATH
value: "/home/roboteamtwente/lib/"
workingDir: /home/roboteamtwente/

- name: LD_LIBRARY_PATH
value: /home/roboteam/build/release/lib
workingDir: /home/roboteam
ports:
- containerPort: 10301
- containerPort: 30011
- containerPort: 10302
- containerPort: 30012
- containerPort: 10300
- containerPort: 30013
resources:
requests:
cpu: 100m
Expand All @@ -147,80 +86,53 @@ spec:
cpu: 500m
memory: 500Mi

# - name: roboteam-interface
# image: roboteamtwente/roboteam:kubernetes
# workingDir: "/home/roboteamtwente/"
# command: ["/bin/sh", "-c"]
# args: ["yarn serve --host 0.0.0.0"]
# ports:
# - containerPort: 8080
# volumeMounts:
# - name: roboteam-interface
# mountPath: /home/roboteamtwente

# - name: roboteam-autoref
# image: gradle:8.4.0-jdk17
# workingDir: "/home/roboteamtwente/"
# command: ["/bin/sh", "-c"]
# args: ["./gradlew run --args=\"-cli --world-ip=127.0.0.1 --world-port=5558 --gc-ip=127.0.0.1 --gc-port=10007\""]
# env:
# - name: GRADLE_USER_HOME
# value: "/home/roboteamtwente/.cache"
# volumeMounts:
# - name: roboteam-autoref
# mountPath: /home/roboteamtwente

# - name: erforce-autoref-sim
# image: roboteamtwente/roboteam:kubernetes
# workingDir: "/home/roboteamtwente/external/autoref/build/bin/"
# command: ["/bin/sh", "-c"]
# args: ["./autoref-cli --vision-port 10020 --tracker-port 10010 --gc-port 10003"]
# volumeMounts:
# - name: roboteam-root
# mountPath: /home/roboteamtwente

# - name: erforce-simulator
# image: roboteamtwente/roboteam:kubernetes
# workingDir: "/home/roboteamtwente/external/framework/build/bin/"
# command: ["/bin/sh", "-c"]
# args: ["./simulator-cli"]
# volumeMounts:
# - name: roboteam-root
# mountPath: /home/roboteamtwente
- name: roboteam-interface
image: roboteamtwente/roboteam:kubernetes
command: ["/bin/sh"]
args: ["-c", "cd /home/roboteam/roboteam_interface && yarn serve --host 0.0.0.0"]
ports:
- containerPort: 8080
resources:
requests:
cpu: 100m
memory: 128Mi
limits:
cpu: 500m
memory: 500Mi

# volumes:
# - name: ssl-game-controller-config
# emptyDir: {}
# - name: ssl-game-controller-data
# emptyDir: {}
# - name: roboteam-build
# persistentVolumeClaim:
# claimName: roboteam-build-pvc
# - name: roboteam-interface
# persistentVolumeClaim:
# claimName: roboteam-interface-pvc
# - name: roboteam-autoref
# persistentVolumeClaim:
# claimName: roboteam-autoref-pvc
# - name: roboteam-root
# persistentVolumeClaim:
# claimName: roboteam-root-pvc
- name: erforce-autoref-sim
image: roboteamtwente/roboteam:kubernetes
command: ["/bin/sh"]
args: ["-c", "cd /home/roboteam/external/autoref/build/bin && ./autoref-cli --vision-port 10020 --tracker-port 10010 --gc-port 10003"]
ports:
- containerPort: 10020
- containerPort: 10003
- containerPort: 10010
resources:
requests:
cpu: 100m
memory: 128Mi
limits:
cpu: 200m
memory: 256Mi

---
apiVersion: v1
kind: Service
metadata:
name: roboteam-simulator-service
spec:
type: NodePort
selector:
app: roboteam-simulator
ports:
- name: ssl-game-controller
port: 8081
targetPort: 8081
nodePort: 30081
- name: roboteam-interface
port: 8080
targetPort: 8080
nodePort: 30080
- name: erforce-simulator
image: roboteamtwente/roboteam:kubernetes
command: ["/bin/sh"]
args:
- "-c"
- "/home/roboteam/external/framework/build/bin/simulator-cli -g 2020 --realism Realistic"
ports:
- containerPort: 10301
- containerPort: 30011
- containerPort: 10302
- containerPort: 30012
- containerPort: 10300
- containerPort: 30013
resources:
requests:
cpu: 100m
memory: 128Mi
limits:
cpu: 500m
memory: 500Mi

0 comments on commit f2e5b5a

Please sign in to comment.