mirror of
https://github.com/ZwareBear/awx.git
synced 2026-03-19 23:33:37 -05:00
fix awx-manage collectstatic failure
when ui_next was never built
This commit is contained in:
9
Makefile
9
Makefile
@@ -536,8 +536,10 @@ docker-compose-build:
|
||||
--cache-from=$(DEV_DOCKER_TAG_BASE)/awx_devel:$(COMPOSE_TAG) .
|
||||
|
||||
docker-clean:
|
||||
-$(foreach container_id,$(shell docker ps -f name=tools_awx -aq && docker ps -f name=tools_receptor -aq),docker stop $(container_id); docker rm -f $(container_id);)
|
||||
-$(foreach image_id,$(shell docker images --filter=reference='*awx_devel*' -aq),docker rmi --force $(image_id);)
|
||||
$(foreach container_id,$(shell docker ps -f name=tools_awx -aq && docker ps -f name=tools_receptor -aq),docker stop $(container_id); docker rm -f $(container_id);)
|
||||
if [ "$(shell docker images | grep awx_devel)" ]; then \
|
||||
docker images | grep awx_devel | awk '{print $$3}' | xargs docker rmi --force; \
|
||||
fi
|
||||
|
||||
docker-clean-volumes: docker-compose-clean docker-compose-container-group-clean
|
||||
docker volume rm -f tools_awx_db tools_grafana_storage tools_prometheus_storage $(docker volume ls --filter name=tools_redis_socket_ -q)
|
||||
@@ -571,7 +573,6 @@ VERSION:
|
||||
PYTHON_VERSION:
|
||||
@echo "$(PYTHON)" | sed 's:python::'
|
||||
|
||||
.PHONY: Dockerfile
|
||||
Dockerfile: tools/ansible/roles/dockerfile/templates/Dockerfile.j2
|
||||
ansible-playbook tools/ansible/dockerfile.yml -e receptor_image=$(RECEPTOR_IMAGE)
|
||||
|
||||
@@ -659,4 +660,4 @@ help/%:
|
||||
|
||||
## Display help for a specific target folder
|
||||
help/%/aliases:
|
||||
@make -s help/all MAKEFILE_LIST="$*/Makefile.aliases"
|
||||
@make -s help/all MAKEFILE_LIST="$*/Makefile.aliases"
|
||||
|
||||
@@ -14,6 +14,11 @@ UI_NEXT_GIT_REPO_SSH ?= git@github.com:ansible/ansible-ui.git
|
||||
UI_NEXT_GIT_REPO_HTTPS ?= https://github.com/ansible/ansible-ui.git
|
||||
UI_NEXT_GIT_BRANCH ?= main
|
||||
|
||||
# awx-manage collect static require the awx/ui_next/build to exist
|
||||
# therefore we have to commit the build directory to source control
|
||||
# so that make docker-compose will be able to start up uwsgi
|
||||
# UI_NEXT_BUILT_FILE is here so that we can use it as the non-phony build target
|
||||
UI_NEXT_BUILT_FILE = $(UI_NEXT_DIR).ui-built
|
||||
|
||||
.PHONY: ui_next/clone-https
|
||||
## Shallow clone the ui_next repo via https skip if UI_NEXT_GIT_REPO_HTTPS is undefined
|
||||
@@ -72,30 +77,37 @@ ui_next/src/build: ui_next/src
|
||||
## Copy ui_next/src/build to ui_next/build
|
||||
ui_next/build: ui_next/src/build
|
||||
cp -r $(UI_NEXT_SRC_DIR)/build $(UI_NEXT_BUILD_DIR)
|
||||
touch $(UI_NEXT_BUILT_FILE)
|
||||
|
||||
## Alias for ui_next/build, will not run if build already exist
|
||||
## non PHONY target for ui_next/build. Will not run if build already exist
|
||||
$(UI_NEXT_BUILT_FILE):
|
||||
$(MAKE) ui_next/build
|
||||
|
||||
## Alias for ui_next/build.
|
||||
.PHONY: $(UI_NEXT_BUILD_DIR)
|
||||
$(UI_NEXT_BUILD_DIR):
|
||||
$(MAKE) ui_next/build
|
||||
|
||||
## Alias for ui_next/clean
|
||||
$(UI_NEXT_DIR)clean:
|
||||
rm -rf $(UI_NEXT_DIR)/src
|
||||
rm -rf $(UI_NEXT_DIR)/build
|
||||
rm -rf $(UI_NEXT_SRC_DIR)
|
||||
rm -rf $(UI_NEXT_BUILD_DIR)
|
||||
|
||||
.PHONY: ui_next/clean
|
||||
## Clean ui_next
|
||||
ui_next/clean: ui_next/clean/build
|
||||
rm -rf $(UI_NEXT_DIR)/src
|
||||
rm -rf $(UI_NEXT_SRC_DIR)
|
||||
|
||||
.PHONY: ui_next/clean/src
|
||||
## Clean ui_next src
|
||||
ui_next/clean/src:
|
||||
rm -rf $(UI_NEXT_DIR)/src
|
||||
rm -rf $(UI_NEXT_SRC_DIR)
|
||||
|
||||
.PHONY: ui_next/clean/build
|
||||
## Clean ui_next build
|
||||
ui_next/clean/build:
|
||||
rm -rf $(UI_NEXT_DIR)/build
|
||||
rm -rf $(UI_NEXT_BUILD_DIR)
|
||||
rm -rf $(UI_NEXT_BUILT_FILE)
|
||||
|
||||
print-%:
|
||||
@echo $($*)
|
||||
Reference in New Issue
Block a user