mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-06-24 01:11:15 -04:00
Merge pull request #1373 from alphagov/imdad-feat-remove-wheels-and-optimise-deploy
Speed up deployment (cleanup wheels/vendor dependencies for cf)
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@@ -23,7 +23,7 @@ var/
|
||||
.installed.cfg
|
||||
*.egg
|
||||
venv/
|
||||
wheelhouse/
|
||||
vendor/
|
||||
|
||||
# PyInstaller
|
||||
# Usually these files are written by a python script from a template
|
||||
|
||||
6
Makefile
6
Makefile
@@ -85,7 +85,9 @@ generate-version-file: ## Generates the app version file
|
||||
.PHONY: build
|
||||
build: dependencies generate-version-file ## Build project
|
||||
npm run build
|
||||
. venv/bin/activate && PIP_ACCEL_CACHE=${PIP_ACCEL_CACHE} pip-accel wheel --wheel-dir=wheelhouse -r requirements.txt
|
||||
. venv/bin/activate && PIP_ACCEL_CACHE=${PIP_ACCEL_CACHE} pip-accel install -r requirements.txt
|
||||
mkdir -p vendor/
|
||||
cp -r ${PIP_ACCEL_CACHE}/sources/ vendor/
|
||||
|
||||
.PHONY: cf-build
|
||||
cf-build: dependencies generate-version-file ## Build project
|
||||
@@ -199,7 +201,7 @@ clean-docker-containers: ## Clean up any remaining docker containers
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -rf node_modules cache target venv .coverage wheelhouse
|
||||
rm -rf node_modules cache target venv .coverage vendor
|
||||
|
||||
.PHONY: cf-login
|
||||
cf-login: ## Log in to Cloud Foundry
|
||||
|
||||
@@ -2,4 +2,4 @@
|
||||
|
||||
echo "Install dependencies"
|
||||
cd /home/notify-app/notifications-admin;
|
||||
pip3 install --find-links=wheelhouse -r /home/notify-app/notifications-admin/requirements.txt
|
||||
pip3 install --find-links=vendor -r /home/notify-app/notifications-admin/requirements.txt
|
||||
|
||||
Reference in New Issue
Block a user