Skip to content

Commit 180daca

Browse files
committed
testing with sh in main dir as well
1 parent 4950ede commit 180daca

File tree

2 files changed

+19
-6
lines changed

2 files changed

+19
-6
lines changed

.devcontainer/Dockerfile

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,8 @@ RUN echo "${USERNAME} ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/${USERNAME} \
5151
# WORKDIR /workspaces/uipa
5252

5353
# Copy requirements.txt and init_db.sh to the container
54-
55-
# COPY requirements.txt /workspaces/uipa/ worked when moved inside same dir of docker
5654
COPY ../requirements.txt /workspaces/uipa/
57-
58-
59-
# COPY init_db.sh tmp/workspaces/uipa/data/seed/
60-
COPY ../init_db.sh /workspaces/uipa/data/seed/
55+
COPY ../init_db.sh /workspaces/uipa/
6156

6257
# Debugging: display the contents of requirements.txt
6358
RUN echo "Displaying requirements.txt:" && cat /workspaces/uipa/requirements.txt

init_db.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#!/bin/bash
2+
# init_db.sh - Initialize the database to the point before uploading public
3+
# body data.
4+
#
5+
6+
echo "Run initial migration..."
7+
python manage.py migrate
8+
9+
echo
10+
echo "Create and populate the search index..."
11+
python manage.py search_index --populate
12+
13+
echo
14+
echo "Load the seed data..."
15+
python manage.py loaddata uipa_org/fixtures/*
16+
17+
echo
18+
echo "Now you can start the dev web server."

0 commit comments

Comments
 (0)