From b3a5dbb62632bdf33a555abe7cb056528e1443b7 Mon Sep 17 00:00:00 2001 From: Logan Cusano Date: Mon, 23 Jun 2025 01:11:50 -0400 Subject: [PATCH] Revert "Update docker to use supervisor" This reverts commit 3086da0e2bd9e096e9644e80fcf81bf70ba96197. --- Dockerfile | 7 ++----- op25-liq.service | 15 +++++++++++++++ supervisord.conf | 20 -------------------- 3 files changed, 17 insertions(+), 25 deletions(-) create mode 100644 op25-liq.service delete mode 100644 supervisord.conf diff --git a/Dockerfile b/Dockerfile index c906535..e1d3960 100644 --- a/Dockerfile +++ b/Dockerfile @@ -66,8 +66,5 @@ COPY ./app/internal/opus /app/internal/opus # Copy the rest of the directory contents into the container at /app COPY ./app /app -# Add Supervisord configuration -COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf - -# Modify the ENTRYPOINT to run Supervisord -ENTRYPOINT ["/usr/bin/supervisord", "-n", "-c", "/etc/supervisor/conf.d/supervisord.conf"] \ No newline at end of file +# Run the node script +ENTRYPOINT ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8001", "--reload"] \ No newline at end of file diff --git a/op25-liq.service b/op25-liq.service new file mode 100644 index 0000000..db8d3ff --- /dev/null +++ b/op25-liq.service @@ -0,0 +1,15 @@ +[Unit] +Description=op25-liq +After=syslog.target network.target nss-lookup.target network-online.target +Requires=network-online.target + +[Service] +User=1000 +Group=1000 +WorkingDirectory=/op25/op25/gr-op25_repeater/apps +ExecStart=/usr/bin/liquidsoap op25.liq +RestartSec=5 +Restart=on-failure + +[Install] +WantedBy=multi-user.target \ No newline at end of file diff --git a/supervisord.conf b/supervisord.conf deleted file mode 100644 index 759ffb5..0000000 --- a/supervisord.conf +++ /dev/null @@ -1,20 +0,0 @@ -[supervisord] -nodaemon=true - -[program:op25-liq] -command=/usr/bin/liquidsoap /op25/op25.liq -directory=/op25 -autostart=true -autorestart=true -stderr_logfile=/var/log/supervisor/op25-liq.err.log -stdout_logfile=/var/log/supervisor/op25-liq.out.log -user=root - -[program:drb-client-discord] -command=uvicorn main:app --host 0.0.0.0 --port 8001 --reload -directory=/app -autostart=true -autorestart=true -stderr_logfile=/var/log/supervisor/main_app.err.log -stdout_logfile=/var/log/supervisor/main_app.out.log -user=root \ No newline at end of file