Skip to content
This repository was archived by the owner on Mar 27, 2023. It is now read-only.

Commit b702c18

Browse files
committed
added vuepress documentation to site
1 parent 738d703 commit b702c18

File tree

8 files changed

+50
-20
lines changed

8 files changed

+50
-20
lines changed

.gitlab-ci.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,11 @@ Build Documentation:
2020
before_script:
2121
- echo "ok"
2222
script:
23-
- ./documentation/build_docs.sh
23+
- ./documentation/build_documentation.sh
24+
artifacts:
25+
paths:
26+
- documentation/docs/.vuepress/public
27+
expire_in: 7 days
2428

2529
.Pytest:
2630
image: python:3.7

README.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,17 @@ Open `http://localhost` in your browser.
2929

3030
You can specify environment variables for docker-compose by adding an `.env` file to the root of the project based on `.env.template`.
3131

32+
## VuePress Documentation
33+
34+
This project uses VuePress for documentation. To view the documentation site locally, run the following command:
35+
36+
```bash
37+
docker-compose -f compose/docs.yml up --build
38+
```
39+
40+
This will make the docs available at `http://localhost:8082/docs/`. Hot-reloading through websockets is supported, so changes will show up as they are saved in your code editor.
41+
42+
3243
### Access Django Shell in Jupyter Notebook
3344

3445
With all containers running, run the following commands:
@@ -88,6 +99,5 @@ docker-compose -f docker-compose.ci.yml -f cypress.yml up
8899
- Put django apps in apps folder
89100
- Redeploy django app to check settings files
90101
- Add GitLab pages site for Group project
91-
- Decide how to build the documentation site (quasar, vuepress?)
92102
- Add file upload examples with Django REST Framework
93103
- Setup password reset

compose/docs.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@ version: '3.7'
22

33
services:
44
vuepress:
5+
container_name: vuepress
56
build:
67
context: ../documentation
78
command: ["sh", "/app/start_dev.sh"]
89
ports:
9-
- "8082:8082"
10+
- "8082:8080"
11+
- "8081:8081"
1012
volumes:
11-
- ./documentation/docs:/app/docs
13+
- ../documentation/docs:/app/docs

docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ services:
3232
environment:
3333
- REDIS_HOST=redis
3434
ports:
35-
- "8081:8081"
35+
- "8085:8081"
3636
networks:
3737
- main
3838

documentation/docs/.vuepress/config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
module.exports = {
22
title: 'Verbose Equals True',
33
base: '/docs/',
4-
port: 8082,
4+
port: 8080,
55
dest: "public",
66
plugins: {
77
'@vuepress/google-analytics': {

documentation/docs/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,5 @@ features:
1313
details: This project aims to be accessible to people with all levels of skill.
1414
footer: MIT Licensed | Copyright © 2018-present Brian Caffey
1515
---
16+
17+
Home page?

quasar/src/pages/Services/documentation.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,11 @@
11
const documentationLinks = [
2+
{
3+
icon: "book",
4+
name: "Documentation for this project",
5+
href: "http://localhost:8082/docs/",
6+
type: "a",
7+
target: "_blank"
8+
},
29
{
310
name: "Django",
411
href: "https://docs.djangoproject.com/en/2.2/",
Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,4 @@
1-
const services = [
2-
{
3-
icon: "local_florist",
4-
name: "Flower",
5-
href: "http://localhost/flower",
6-
type: "a",
7-
target: "_blank"
8-
},
1+
let services = [
92
{
103
icon: "verified_user",
114
name: "Django",
@@ -14,16 +7,16 @@ const services = [
147
target: "_blank"
158
},
169
{
17-
icon: "email",
18-
name: "Mailhog",
19-
href: "http://localhost:8025",
10+
icon: "local_florist",
11+
name: "Flower",
12+
href: "http://localhost/flower",
2013
type: "a",
2114
target: "_blank"
2215
},
2316
{
24-
icon: "storage",
25-
name: "Redis Commander",
26-
href: "http://localhost:8081",
17+
icon: "email",
18+
name: "Mailhog",
19+
href: "http://localhost:8025",
2720
type: "a",
2821
target: "_blank"
2922
},
@@ -36,4 +29,16 @@ const services = [
3629
}
3730
];
3831

32+
if (process.env.NODE_ENV === "development") {
33+
services = [ ...services,
34+
{
35+
icon: "storage",
36+
name: "Redis Commander",
37+
href: "http://localhost:8081",
38+
type: "a",
39+
target: "_blank"
40+
}
41+
];
42+
}
43+
console.log(JSON.stringify(services));
3944
export default services;

0 commit comments

Comments
 (0)