Skip to content

Commit

Permalink
New path
Browse files Browse the repository at this point in the history
  • Loading branch information
fsoest committed Jan 10, 2025
1 parent 0bb9628 commit 6281951
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 9 deletions.
1 change: 0 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ EXPOSE 80

RUN chmod +x ./init.sh
RUN chmod +x S1/initial_setup.sh
RUN chmod -R 777 S1

RUN apk add --no-cache nginx
COPY config/default.conf /etc/nginx/http.d/default.conf
Expand Down
11 changes: 3 additions & 8 deletions S1/waitinglists/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -245,16 +245,11 @@ def update_attendance(request, session_id):
pass
check_modules(attendance.user.id)
if session.module.name == "Module 1":
if not os.path.exists("opt/s1/S1/db/moodle-signup"):
os.makedirs("opt/s1/S1/db/moodle-signup")
if not os.path.exists("/opt/s1/S1/db/moodle-signup"):
os.makedirs("/opt/s1/S1/db/moodle-signup")
Path(
f"opt/s1/S1/db/moodle-signup/{attendance.user.username}"
f"/opt/s1/S1/db/moodle-signup/{attendance.user.username}"
).touch(exist_ok=True)
with open(
f"opt/s1/{attendance.user.username}",
"w",
) as f:
f.write("1")
# enrol_and_check_overrides(attendance.user.username)
elif attendance.attended == "ABS":
try:
Expand Down

0 comments on commit 6281951

Please sign in to comment.