Skip to content

Commit 2276f28

Browse files
committed
Tweaked dockerfile to add Make, changing filenames to standardise, starting to document run process.
1 parent 6805cbc commit 2276f28

4 files changed

Lines changed: 43 additions & 4 deletions

File tree

.env.default

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
DEBUG=True
22
DEBUG_IOMMI=True
3-
# When false, access control is turned off
4-
DEBUG_ACCESS=True
53
# Generated from http://portal.azure.com/ -> Cloud shell
64
# Connect-AzureAD
75
# $azureADAppReg = New-AzureADApplication -DisplayName TeachingTimeTool -AvailableToOtherTenants $false

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
FROM ghcr.io/astral-sh/uv:alpine
22

3-
RUN apk add --update gcc linux-headers musl-dev openldap-dev python3-dev bash
3+
RUN apk add --update gcc linux-headers musl-dev openldap-dev python3-dev bash make
44

55
# set environment variables
66
ENV PIP_DISABLE_PIP_VERSION_CHECK 1

README.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,43 @@
11
# Teaching Time Tool
22

3+
## Installation
4+
5+
Clone the repo to the server:
6+
7+
```bash
8+
cd /var/www/
9+
git clone https://github.com/Southampton-RSG/physics-workload
10+
```
11+
12+
## Running
13+
14+
The tool is run using `docker compose`. Generally, it's best to do this in a `screen` session.
15+
Start the server (and associated containers) using:
16+
17+
```bash
18+
screen
19+
sudo docker compose up
20+
```
21+
22+
### Initialising
23+
24+
If you're running this the first time, the database has to be initialised.
25+
This will populate the database with
26+
27+
```bash
28+
sudo docker exec -it physics-workload-django /bin/bash
29+
make clean
30+
make data
31+
```
32+
33+
34+
## Updating
35+
36+
To update the tool, take the containers down, rebuild, and restart using:
37+
38+
```bash
39+
screen -r
40+
sudo docker compose down
41+
sudo docker compose build --no-cache
42+
sudo docker compose up
43+
```

scripts/import_unit_tasks_from_csv.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
# logger.propagate = True
2424

2525
# Hardcoded for ease of dealing with the manage.py shell.
26-
CSV_PATH: Path = Path(getcwd()) / "staff_tasks_unit.csv"
26+
CSV_PATH: Path = Path(getcwd()) / "spreadsheet_tasks_unit.csv"
2727
logger.info(f"Importing units from: {CSV_PATH}")
2828

2929
# Track the history of creation

0 commit comments

Comments
 (0)