File: rules

package info (click to toggle)
mistral 19.0.0-2
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 16,200 kB
  • sloc: python: 56,478; sh: 722; makefile: 54
file content (71 lines) | stat: -rwxr-xr-x 4,017 bytes parent folder | download | duplicates (2)
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#!/usr/bin/make -f

include /usr/share/openstack-pkg-tools/pkgos.make

%:
	dh $@  --with python3

override_dh_auto_clean:
	python3 setup.py clean
	rm -f debian/*.init debian/*.service debian/*.upstart debian/mistral-common.postinst debian/mistral-common.config
	rm -rf debian/mistral-common.postrm debian/*.templates debian/po debian/mistral-api.config debian/mistral-api.postinst
	rm -rf build .stestr *.egg-info
	find . -iname '*.pyc' -delete
	for i in $$(find . -type d -iname __pycache__) ; do rm -rf $$i ; done

override_dh_auto_build:
	/usr/share/openstack-pkg-tools/pkgos_insert_include pkgos_func mistral-common.postinst
	/usr/share/openstack-pkg-tools/pkgos_insert_include pkgos_func mistral-common.config
	/usr/share/openstack-pkg-tools/pkgos_insert_include pkgos_func mistral-api.config
	/usr/share/openstack-pkg-tools/pkgos_insert_include pkgos_func mistral-api.postinst
	/usr/share/openstack-pkg-tools/pkgos_insert_include pkgos_postrm mistral-common.postrm
	pkgos-merge-templates mistral-api mistral endpoint
	pkgos-merge-templates mistral-common mistral db rabbit ksat

override_dh_auto_install:
	echo "Do nothing..."

override_dh_auto_test:
	echo "Do nothing..."

override_dh_install:
	set -e ; for pyvers in $(PYTHON3S); do \
		python$$pyvers setup.py install --install-layout=deb --root $(CURDIR)/debian/tmp; \
	done

ifeq (,$(findstring nocheck, $(DEB_BUILD_OPTIONS)))
	pkgos-dh_auto_test --no-py2 'mistral\.tests\.(?!(.*unit\.actions\.openstack\.test_generator\.GeneratorTest\.test_generator.*|.*api\.v2\.test_action_executions\.TestActionExecutionsController\.test_get_all_with_and_without_output.*|.*unit\.actions\.test_std_mistral_http_action\.MistralHTTPActionTest\.test_http_action.*|.*unit\.actions\.test_std_http_action\.HTTPActionTest\.test_http_action.*|.*engine\.test_action_heartbeat_checker\.ActionHeartbeatCheckerTest\.test_fail_action_with_missing_heartbeats_wf_spec_not_cached.*|.*unit\.engine\.test_dataflow\.DataFlowTest\.test_context_view_eval_keys.*|.*unit\.engine\.test_action_heartbeat_sender\.ActionHeartbeatSenderRemoteExecutorTest\.test_long_action_failure_with_disabled_sender.*|.*unit\.engine\.test_action_heartbeat_sender\.ActionHeartbeatSenderLocalExecutorTest\.test_long_action_failure_with_disabled_sender|.*unit\.scheduler\.test_default_scheduler\.DefaultSchedulerTest.*|.*unit\.services\.test_event_engine\.EventEngineTest\.test_process_event_queue.*|.*unit\.services\.test_event_engine\.EventEngineTest\.test_event_engine_public_trigger.*|.*unit\.engine\.test_action_heartbeat_checker\.ActionHeartbeatCheckerTest\.test_fail_action_with_missing_heartbeats.*))'

endif


	# Copy the configuration files
	set -e ; for i in logging.conf wf_trace_logging.conf ; do \
		install -D -m 0664 etc/$$i.sample $(CURDIR)/debian/mistral-common/usr/share/mistral-common/$$i ; \
	done
	install -D -m 0664 etc/policy.json $(CURDIR)/debian/mistral-common/usr/share/mistral-common/policy.json ; \
	PYTHONPATH=$(CURDIR)/debian/tmp/usr/lib/python3/dist-packages oslo-config-generator \
		--namespace mistral.config \
		--namespace oslo.db \
		--namespace oslo.messaging \
		--namespace oslo.middleware.cors \
		--namespace oslo.middleware.http_proxy_to_wsgi \
		--namespace keystonemiddleware.auth_token \
		--namespace oslo.log \
		--namespace oslo.policy \
		--namespace oslo.service.sslutils \
		--output-file $(CURDIR)/debian/mistral-common/usr/share/mistral-common/mistral.conf
	pkgos-readd-keystone-authtoken-missing-options $(CURDIR)/debian/mistral-common/usr/share/mistral-common/mistral.conf keystone_authtoken mistral

	PYTHONPATH=$(CURDIR)/debian/tmp/usr/lib/python3/dist-packages oslopolicy-sample-generator \
		--output-file $(CURDIR)/debian/mistral-common/usr/share/mistral-common/policy.json \
		--format json \
		--namespace mistral

	pkgos-fix-config-default $(CURDIR)/debian/mistral-common/usr/share/mistral-common/mistral.conf keystone_authtoken auth_protocol http

	dh_install
	dh_missing --fail-missing

override_dh_python3:
	dh_python3 --shebang=/usr/bin/python3