Update Dockerfile and commander.py

This commit is contained in:
Richard Bronkhorst 2023-06-11 21:17:50 +02:00
parent af73939e03
commit 2346b610a3
2 changed files with 4 additions and 2 deletions

View File

@ -1,4 +1,4 @@
FROM python:3.10
FROM python:3
RUN useradd -ms /bin/bash user
RUN mkdir /data && chown user /data
USER user
@ -6,7 +6,7 @@ ADD --chown=user requirements.txt /app/requirements.txt
WORKDIR /app
RUN pip3 install -r requirements.txt
ADD --chown=user . /app
RUN chmod +x /app/main.py
RUN chmod +x /app/commander.py
VOLUME /data
ENTRYPOINT [ "python3", "/app/main.py"]
CMD ["-s", "/data/"]

View File

@ -56,6 +56,7 @@ class Commander(CommandLine):
for w in waypoints:
if 'MARKETPLACE' in w.traits:
self.api.marketplace(w)
print(f'marketplace at {w}')
sleep(0.5)
def all_waypoints(self, systems):
@ -64,6 +65,7 @@ class Commander(CommandLine):
break
r = self.api.list_waypoints(s)
print(f'system {s}: {len(r)} waypoints')
self.all_specials(r)
sleep(0.5)
def all_systems(self):