shove ui-next build into /var/lib/awx/public/static/media

This commit is contained in:
Hao Liu
2023-03-08 23:23:28 -05:00
parent 4684e9f0f6
commit 43911ecab1
3 changed files with 4 additions and 21 deletions

View File

@@ -298,7 +298,7 @@ TEMPLATES = [
os.path.join(BASE_DIR, 'templates'),
os.path.join(BASE_DIR, 'ui', 'build'),
os.path.join(BASE_DIR, 'ui', 'public'),
os.path.join(BASE_DIR, 'ui_next', 'build', 'awx'),
os.path.join(BASE_DIR, 'ui_next', 'build', 'media'),
],
},
]

View File

@@ -102,7 +102,8 @@ $(UI_NEXT_SRC_DIR)/node_modules/webpack:
## Copy ui_next/src/build to ui_next/build
ui_next/build:
$(MAKE) $(UI_NEXT_SRC_DIR)/build
@cp -r $(UI_NEXT_SRC_DIR)/build $(UI_NEXT_DIR_ABS) &&\
@mkdir $(UI_NEXT_DIR_ABS)/build && \
cp -r $(UI_NEXT_SRC_DIR)/build/awx $(UI_NEXT_DIR_ABS)/build/media &&\
touch $(UI_NEXT_BUILT_FILE)
## Alias for ui_next/build. Will not run if .ui-built file already exist

View File

@@ -9,24 +9,6 @@ class IndexView(TemplateView):
template_name = 'index_awx.html'
# TODO: Hao fix this
class MigrationsNotran(TemplateView):
template_name = 'installing.html'
def get_context_data(self, **kwargs):
context = super().get_context_data(**kwargs)
product_name = server_product_name()
context['title'] = _('%s Upgrading' % product_name)
context['image_alt'] = _('Logo')
context['aria_spinner'] = _('Loading')
context['message_upgrade'] = _('%s is currently upgrading.' % product_name)
context['message_refresh'] = _('This page will refresh when complete.')
return context
app_name = 'ui_next'
urlpatterns = [
re_path(r'^$', IndexView.as_view(), name='index'),
re_path(r'^migrations_notran/$', MigrationsNotran.as_view(), name='migrations_notran'),
]
urlpatterns = [re_path(r'^$', IndexView.as_view(), name='index')]