Skip to content

Latest commit

 

History

History
134 lines (93 loc) · 4.06 KB

port-project.md

File metadata and controls

134 lines (93 loc) · 4.06 KB

Port Project

Table of Contents

Overview

from to
Core CMS Resources Core CMS Custom
built into Core CMS image built atop Core CMS image

Create a New Project

Follow steps in Create a New Project.

Reminders
  1. Move Content
    From Core CMS Resources /taccsite_custom/custom_project_dir.
    To /custom_project_dir/src/taccsite_custom/custom_project_dir
  2. Copy Settings
    From TACC/Core-Portal-Deployments:/project_dir/camino/settings_custom.py.
    To /custom_project_dir/src/taccsite_cms/settings_custom.py.1
  3. Use Not
    custom_project_dir custom-project-dir

    Important A valid Python application uses underscores.

Migrate Project to Core CMS v3.12

Follow Core CMS: Upgrade Project: from v3.N to v3.12.

Known Gotchas

If the custom project has a Core Portal i.e. settings has FAVICON and:

  • either settings has INCLUDES_CORE_PORTAL = True
  • or settings does not have INCLUDES_CORE_PORTAL

Then:

  1. You must edit Core Portal Deployments.
  2. Edit Portal settings for the appropriate server.
    E.g. project_dir/camino/___.settings_custom.py where ___ is dev, pprd, prod as appropriate (not cms).
  3. Update _PORTAL_ICON_FILENAME:
    if is_remote is then set value to
    False /static/ + the img_file_src of FAVICON
    True the img_file_src of FAVICON

Expects CSS Build Step

to Import Core Styles CSS

If the custom project directory expects CSS build step e.g. has

  • css/src/*.css with @import of a @tacc/core-styles/ path

Then:

  1. Contact https://github.com/wesleyboar.

Note Those @imports assume:

  • Node
  • NPM package @tacc/core-styles
  • a CSS build script

Whether to support those here, and how to port without support for those, has not been decided.

to Import Internal Stylesheets

If the custom project directory expects CSS concatenation e.g. has

  • css/src/*.css with @import of a relative path

Then:

  1. Rename import paths appended with comment Core-CMS:/taccsite_cms/…/:
    • from **/*.css
    • to /static/site_cms/css/build/*.css
  2. Rename relative import paths (e.g. ./**/*.css):
    • from **/*.css
    • to /static/custom_project_dir/css/**/*.css
  3. Add UI test steps to initial deploy of ported custom project.

Uses Custom CSS

If the custom project directory expects any CSS at all i.e. has

  • a template with <link rel="stylesheet" href="{% static

Then:

  1. Move CSS tree:
    • from .../custom_project_dir/static/css/src/
    • to .../custom_project_dir/static/css/
  2. Rename href paths:
    • from custom_project_dir/css/build/**/*.css
    • to custom_project_dir/css/**/*.css
  3. Add UI test steps to initial deploy of ported custom project.

Footnotes

  1. The cms.settings_custom.py is committed in Core Portal Deployments. A settings_custom.py in Core CMS Custom is .gitignore'd.