Skip to content

Commit 2a5e612

Browse files
authored
docs: update docs since TACC/Core-CMS#741 (#196)
* docs: update docs since TACC/Core-CMS#741 * docs: restore debug-project.md
1 parent 88495fd commit 2a5e612

File tree

3 files changed

+39
-56
lines changed

3 files changed

+39
-56
lines changed

README.md

+17-43
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ A CMS project is run within [Core CMS]. Also, [Git Submodules] must be pre-insta
7070

7171
Set up a new local CMS instance.
7272

73-
0. Core CMS:
73+
0. Set up Core CMS to run a local Core CMS Resources:
7474

7575
1. If not already done:
7676
1. Clone [Core CMS] repository.
@@ -96,31 +96,27 @@ Set up a new local CMS instance.
9696
ln -s '../taccsite_custom/custom_project_dir/settings_custom.py' 'taccsite_cms/settings_custom.py'
9797
```
9898

99-
1. Docker Containers:
99+
1. Enter the CMS Docker Container:
100100

101101
```sh
102102
docker exec -it core_cms /bin/bash
103-
# This opens a command prompt within the container.
103+
# This opens a command prompt within the container
104104
```
105105

106-
2. Django Application:
106+
2. Update the Django Application:
107107

108108
(Run these commands within the container.)
109109

110110
```sh
111111
python manage.py migrate
112-
# For projects that install apps
113-
# e.g. ECEP installs News/Blog
114-
npm ci
115-
npm run build:css --project="custom_project_dir"
116-
# If output includes
117-
# "Input Error: You must pass a valid"
118-
# then double check you have the directory
119-
# `taccsite_cms/…/static/…/css/src`
112+
python manage.py createsuperuser
113+
# To use default "Username" and skip "Email address", press Enter at both prompts.
114+
# At "Password" prompts, you may use an easy-to-remember password.
120115
python manage.py collectstatic --no-input
116+
121117
```
122118

123-
3. Django CMS:
119+
3. Open Django CMS:
124120
1. Open http://localhost:8000/.
125121
2. Verify anything specific to the custom project is present e.g.
126122
- logo
@@ -132,41 +128,15 @@ Set up a new local CMS instance.
132128
> A local machine CMS will be empty. It will **not** have content from staging nor production. To have that, follow and adapt instructions to [copy a database](https://confluence.tacc.utexas.edu/x/W4DZDg).
133129

134130
> **Note**
135-
> A local machine CMS does **not** include **nor** integrate with an instance of [Core Portal]. There are no reliable instructions to do either. **Help welcome.**
131+
> A local machine CMS does **not** include **nor** integrate with an instance of [Core Portal]. To attempt to do that, follow [How to Use a Custom Docker Compose File](https://github.com/TACC/Core-CMS/wiki/How-to-Use-a-Custom-Docker-Compose-File) and [Locally Develop CMS Portal Docs](https://github.com/TACC/Core-CMS/wiki/Locally-Develop-CMS---Portal---Docs). **Help welcome.**
136132

137133
## Update Project
138134

139-
To update an existing CMS instance.
140-
141-
### New Major [Core CMS] Version (or v3.12)
142-
143-
Read [Upgrade Project] for developer instructions.
135+
Follow [Core CMS: Update Project](https://github.com/TACC/Core-CMS/blob/main/README.md#update-project) instructions.
144136

145-
### New Branch (or Minor or Patch [Core CMS] Version)
137+
## Develop Project
146138

147-
1. If CMS Docker files changed, rebuild Docker Containers:
148-
149-
```sh
150-
cd custom_project_dir
151-
make stop
152-
make build
153-
make start
154-
```
155-
156-
2. If static assets or database models changed, update the Django Application:
157-
158-
```sh
159-
docker exec -it core_cms /bin/bash
160-
# That opens a command prompt within the container.
161-
python manage.py migrate
162-
python manage.py collectstatic --no-input
163-
# If the project has no new/changed assets,
164-
# then expect output of "0 static files […]"
165-
```
166-
167-
## Run Multiple Projects
168-
169-
Read [Multiple Projects](./docs/run-project.md#multiple-projects).
139+
Follow "via Core CMS Resources" section of [Core CMS: Develop Custom Project](https://github.com/TACC/Core-CMS/blob/main/docs/develop-custom-project.md#via-core-cms-resources).
170140

171141
## Debug Project
172142

@@ -176,6 +146,10 @@ Read [Debug Project](./docs/debug-project.md) for miscellaneous tips.
176146

177147
Follow "Core-CMS-Resources" section of [How To Build & Deploy][Build & Deploy Project].
178148

149+
## Run Multiple Projects
150+
151+
Read [Run Multiple Projects](./docs/run-multiple-projects.md).
152+
179153
## Port Project
180154

181155
To port a project to [Core CMS Custom], read [Port Project].

docs/debug-project.md

+13
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,16 @@
99

1010
1. Review content of `/taccsite_custom/custom_project_dir/static/custom_project_dir/css/build`.
1111
2. Verify that content is also _in the container_ at `/static/custom_project_dir/css/build`.
12+
13+
> **Note**
14+
> You will never see `/static/*/css/src`, because [this app ignores `src/`][ignore-src-dirs] when [collecting static files](#collect-static-files). This is done so templates can **not** load load source files.
15+
16+
[ignore-src-dirs]: https://github.com/TACC/Core-CMS/blob/7b62db1/taccsite_cms/django/contrib/staticfiles_custom/apps.py
17+
18+
## Restart CMS Server
19+
20+
See [How to Restart the CMS Server](https://github.com/TACC/Core-CMS/wiki/How-to-Restart-the-CMS-Server).
21+
22+
## Build Search Index
23+
24+
See [How to Build Search Index](https://github.com/TACC/Core-CMS/wiki/How-to-Build-Search-Index).

docs/run-project.md docs/run-multiple-projects.md

+9-13
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
1-
# Run Project
1+
# Run Multiple Projects
22

3-
## Individual Projects
4-
5-
No developer instruction beyond those for Core CMS.
6-
7-
## Multiple Projects
3+
## One at a Time
84

95
> **Note**
106
> By default, multiple projects can not be run simultaneously.[^1]
@@ -39,13 +35,7 @@ To stop one project, and run another:
3935
> **Warning**
4036
> With these instructions, if a project has different apps installed, and especially if you used those apps on your local CMS, you will likely encounter an error. This document can **not** help you solve such an error.[^1]
4137

42-
```sh
43-
python manage.py migrate
44-
npm run build:css --project="custom_project_dir"
45-
python manage.py collectstatic --no-input
46-
```
47-
48-
[^1]: If you want to run multiple projects simultaneously, and avoid the Warning for multiple projects, see [Simultaneous Projects](#simultaneous-projects).
38+
Follow [Core CMS: Getting Started: Build & Start the Docker Containers](https://github.com/TACC/Core-CMS/blob/main/README.md#build--start-the-docker-containers) instructions.
4939

5040
## Simultaneous Projects
5141

@@ -57,3 +47,9 @@ To run multiple projects simultaneously:
5747
1. Create another clone of [Core CMS].
5848
2. Set up the CMS in that clone.
5949
3. Set up the other project in that CMS.
50+
51+
[^1]: If you want to run multiple projects simultaneously, and avoid the Warning for multiple projects, see [Simultaneous Projects](#simultaneous-projects).
52+
53+
<!-- Link Aliases -->
54+
55+
[Core CMS]: https://github.com/TACC/Core-CMS

0 commit comments

Comments
 (0)