-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathMakefile
49 lines (35 loc) · 1.39 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
.PHONY: all build lint requirements setup test
all: up
build:
docker-compose build
clean:
docker-compose down -v --remove-orphans
cypress:
# Turn on local system, and open cypress in interactive mode
docker-compose up -d && cd e2e && npm install && npm run test
debug:
# Stop the canonical ckan container to avoid a port collision. Use `run`
# so that we have interactive console access for the debugger.
docker-compose stop ckan ; docker-compose run --service-ports ckan
requirements:
docker-compose run --rm -T ckan /app/bin/requirements.sh
lint:
flake8 . --count --show-source --statistics
restart:
docker-compose restart ckan
test-build:
docker-compose -f docker-compose.yml -f docker-compose.test.yml build
test:
docker-compose -f docker-compose.yml -f docker-compose.test.yml up --abort-on-container-exit test
test_extension:
docker-compose run --rm -T ckan pytest --cov=ckanext.datagov_inventory --disable-warnings /app/ckanext/datagov_inventory/tests/
up:
docker-compose up $(ARGS)
clear-solr-volume:
# Destructive
docker stop $(shell docker volume rm catalogdatagov_solr_data 2>&1 | cut -d "[" -f2 | cut -d "]" -f1)
docker rm $(shell docker volume rm catalogdatagov_solr_data 2>&1 | cut -d "[" -f2 | cut -d "]" -f1)
docker volume rm catalogdatagov_solr_data
unlock-solr-volume:
# Corruptible
docker-compose run solr /bin/bash -c "rm -rf /var/solr/data/ckan/data/index/write.lock"