Browse Source

fix: syncplay server errors

pull/2/head
Dnomd343 11 months ago
parent
commit
a15ba943da
  1. 2
      Dockerfile
  2. 4
      boot.py

2
Dockerfile

@ -10,6 +10,8 @@ RUN cat /dev/null > requirements_gui.txt
RUN SNAPCRAFT_PART_BUILD=1 pip wheel --wheel-dir /wheels/ ./
FROM ${PYTHON} AS syncplay
WORKDIR /wheels/
RUN pip wheel PyYaml
COPY --from=builder /wheels/ /wheels/
WORKDIR /release/local/lib/
RUN mkdir $(basename /usr/local/lib/python3.*/) && cd ./python3.*/ && \

4
boot.py

@ -23,7 +23,7 @@ def temp_file(file: str, content: str) -> str:
""" Create and save content to temporary files. """
file = os.path.join('/tmp/', file)
with open(file, 'w') as fp:
fp.write(f'{content}\n')
fp.write(content)
return file
@ -67,7 +67,7 @@ def load_config(args: dict[str, Any], file: str) -> dict[str, Any]:
def build_args(opts: dict):
""" Construct the startup arguments for syncplay server. """
args = ['--port', opts.get('port', '8999')]
args = ['--port', str(opts.get('port', 8999))]
if 'password' in opts:
args += ['--password', opts['password']]
if 'motd' in opts:

Loading…
Cancel
Save