250 Commits

Author SHA1 Message Date
Lacey Williams Henschel
fb582afe9c Add temp privacy policy page 2023-05-23 16:31:44 -07:00
Lacey Williams Henschel
8cc6b91cf2 Force content type for js fstatic content 2023-05-11 10:05:31 -07:00
Lacey Williams Henschel
579d61fc82 :❄️ Make STATIC_CACHE_TIMEOUT a string 2023-05-10 11:49:19 -07:00
Lacey Williams Henschel
b88eb50755 Shorten static content cache timeout and serve from a setting 2023-05-04 15:58:21 -07:00
Lacey Williams Henschel
3368a74d8d Merge branch 'main' of github.com:CPPAlliance/boost.org into 153-caching 2023-05-03 13:55:50 -07:00
Frank Wiles
1f9f0deef7 Black 2023-04-26 09:49:57 -05:00
Frank Wiles
73895f9081 Fix renderer tests for new S3 layout 2023-04-26 09:32:30 -05:00
Lacey Williams Henschel
662ebe46f6 Merge branch 'main' of github.com:CPPAlliance/boost.org into 153-caching 2023-04-25 13:26:16 -07:00
Lacey Williams Henschel
a59741b2f2 🔥 Unused import 2023-04-19 13:18:03 -07:00
Lacey Williams Henschel
dc9424520c Picky test things 2023-04-19 13:15:17 -07:00
Lacey Williams Henschel
25e2ff3362 Fix mocked S3 tests 2023-04-19 13:07:14 -07:00
Lacey Williams Henschel
3fe65e7051 👕 Fix imports 2023-04-19 11:24:04 -07:00
Lacey Williams Henschel
2d987242c4 Fix cache tests 2023-04-19 11:21:21 -07:00
Lacey Williams Henschel
b11b129619 Merge branch 'main' of github.com:CPPAlliance/boost.org into 153-caching 2023-04-19 10:47:34 -07:00
Lacey Williams Henschel
8d980068db Improve exception handling and logging 2023-04-18 16:22:48 -07:00
Lacey Williams Henschel
f58d03d4c7 🔈 Add logging 2023-04-18 15:31:05 -07:00
Frank Wiles
ba568a2c6e Fix test that is no longer valid 2023-04-14 16:04:17 -05:00
Frank Wiles
a4e1d2b02f Adjust static content paths for /develop/doc/
- Add feature to static site finding that looks for `/index.html` if URL
  ends with a slash
2023-04-14 15:56:19 -05:00
Frank Wiles
d3b417f8ab Adjust static content settings names
Realized we have a conflict in settings names between S3 hosted
static content and S3 hosted uploaded media content. Prefixing
static content with `STATIC_CONTENT_`
2023-04-06 06:09:09 -05:00
Frank Wiles
10fc6c42e5 Small static content fixes
- We don't need to be setting DEFAULT_FILE_STORAGE after static changes

- Need to be able to correctly pass binary files (images, etc) so need
  to avoid converting to UTF-8 after retrieving from S3

- Moved to simpler CBV
2023-04-06 06:00:01 -05:00
Lacey Williams Henschel
1a42c13353 🚧 Add a placeholder test for caching
Having trouble with the mocks
2023-04-05 14:52:46 -07:00
Lacey Williams Henschel
ed2e2494d3 Add caching logic to static content 2023-04-05 14:48:58 -07:00
Lacey Williams Henschel
4800e7c487 Skip the live API test 2023-04-05 08:59:47 -07:00
Lacey Williams Henschel
83e12164ab Cleanup -- all should work now! 2023-04-05 08:58:18 -07:00
Lacey Williams Henschel
296e67609f Fix some tests
Also changed the config because the test path I had, ironically, led to an html file with a redirect, and that was throwing me for a loop
2023-04-05 08:29:37 -07:00
Lacey Williams Henschel
9ad183fa5a 🔧 Add a second config option 2023-04-05 08:18:06 -07:00
Lacey Williams Henschel
23289868cf 🚧 Progress on config for static content
Works now with the most basic setup: replace /site/develop/ with just / in the url
2023-04-05 07:19:45 -07:00
Lacey Williams Henschel
f8138d498f 🚧 Getting back to a working state without config
Includes these failing tests:
```
=============================== short test summary info ================================
FAILED core/tests/test_renderer.py::test_get_s3_keys - AssertionError: assert '/site/develop/tools/auto_index/index.html' in []
FAILED core/tests/test_views.py::test_static_content_template_view[/site/develop/rst.css] - django.http.response.Http404: Page not found
```
2023-04-05 06:40:36 -07:00
Lacey Williams Henschel
8fab4fca68 🚧 Progress on static content 2023-04-04 21:15:45 -07:00
Lacey Williams Henschel
947318ba65 Fix test 2023-04-04 12:20:39 -07:00
Lacey Williams Henschel
5444e3babe Set the content-type for static content in the response 2023-04-04 12:20:30 -07:00
Lacey Williams Henschel
e0ce223c82 🚧 Separate markdown and static views, fix tests, add template 2023-04-04 12:15:31 -07:00
Lacey Williams Henschel
70b69c56fb 🚧 Hook the Markdown view up to the S3 call 2023-04-04 10:17:39 -07:00
Lacey Williams Henschel
84c33d082d Comment out tests for now 2023-04-04 10:16:52 -07:00
Lacey Williams Henschel
c359f325cd ❄️ Change setting names for AWS 2023-04-04 09:23:04 -07:00
Lacey Williams Henschel
272061508e 🚧 Progress on s3 retrieval 2023-04-03 13:18:21 -07:00
Lacey Williams Henschel
eb213ffba1 WIP: Getting to know boto3 2023-04-03 12:30:33 -07:00
Frank Wiles
b41769aa16 Fixing local vs CI issue 2023-02-27 09:56:00 -06:00
Frank Wiles
8fc5d76057 Setup django-storages for S3 compatible storage when deployed 2023-02-26 14:48:47 -06:00
Lacey Williams Henschel
c7bef4af28 📝 Improve test files 2023-01-19 18:43:49 -08:00
Lacey Williams Henschel
49e83dfcad Set up a local dir for markdown content unit testing 2023-01-19 18:41:13 -08:00
Lacey Williams Henschel
3428012a49 Retrieve markdown from Docker container, render as HTML 2023-01-19 15:37:49 -08:00
Frank Wiles
a8e9085c2c Fix black formatting 2022-09-28 10:55:51 -05:00
Greg Newman
2487c62d28 🚧 Markdown renderer
* Stubbed out TemplateView for rendering markdown files
* Added a BoostRenderer class to parse the markdown files to support the first iteration of a youtube shortcode and also a Pygments renderer for code blocks.
* Added default styles for some common markup so the rendered markdown looks better.

The pygments renderer is set to use Solarized Dark right now because that’s the closest I see that matches the design of the site.  This can be changed in the class.
2022-09-10 11:07:42 -04:00
Greg Newman
c35d7e5927 🚜 removing discovery code 2022-09-10 11:03:54 -04:00
Frank Wiles
546e719295 black 2022-06-24 14:53:02 -05:00
Greg Newman
557a63254b Illustration animations for base template 2022-06-14 15:14:56 -04:00
Frank Wiles
47f0c7cf71 Black codebase 2022-05-26 08:33:31 -05:00
Greg Newman
88aa715d5f Shortcode token 2022-05-23 17:55:52 -04:00
Greg Newman
4490b961d6 parse markdown and frontmatter 2022-05-12 08:45:59 -04:00