This repository has been archived by the owner on Jan 29, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 51
/
Makefile
115 lines (86 loc) · 4.15 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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
# Minimal makefile for Sphinx documentation
#
# You can set these variables from the command line, and also
# from the environment for the first four.
SPHINXOPTS ?= "-W"
SPHINXBUILD ?= sphinx-build
ES_URL ?=
PG_URL ?=
SOURCEDIR = .
BUILDDIR = _build
# Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
.PHONY: help Makefile
# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
# This will overwrite the generated sitemap bu sphinx_sitemap to
# exclude index.html or .html extension in the <url>. This is to prevent
# redirect loop (issue for search engine) since Cloudflare Pages redirect all .html to it's parent
html:
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
python "$(SOURCEDIR)/scripts/postprocess_sitemap.py"
livehtml:
sphinx-autobuild "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
livehtmlall:
sphinx-autobuild -a "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) --watch _static
linkcheck-specified-files:
sphinx-build -b linkcheck --color "$(SOURCEDIR)" "$(BUILDDIR)" $(files)
spell:
vale $(SOURCEDIR)/index.rst
vale $(SOURCEDIR)/docs
# Create and push index to Algolia
index-algolia: html
python "$(SOURCEDIR)/scripts/index_algolia.py" \
--algolia-app-id="$(ALGOLIA_APPLICATION_ID)" \
--algolia-api-key="$(ALGOLIA_ADMIN_KEY)" \
--algolia-index-name="$(ALGOLIA_INDEX_NAME)" \
--html-build-dir="$(BUILDDIR)/html"
# Create Elasticsearch index
create-index:
python "$(SOURCEDIR)/scripts/create_index.py" \
--es-url="$(ES_URL)"
# Index Developer Portal pages to Elasticsearch
index-devportal: html
python "$(SOURCEDIR)/scripts/index_developer_portal_pages.py" \
--es-url="$(ES_URL)" \
--html-build-dir="$(BUILDDIR)/html"
# Create feedback table to PG
create-feedback-table:
python "$(SOURCEDIR)/scripts/create_feedback_table.py" \
--pg-url="$(PG_URL)"
# (Re)Generate config listing for a service type
service-type-config-cassandra:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "cassandra" "includes/config-cassandra.rst"
service-type-config-clickhouse:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "clickhouse" "includes/config-clickhouse.rst"
service-type-config-flink:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "flink" "includes/config-flink.rst"
service-type-config-grafana:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "grafana" "includes/config-grafana.rst"
service-type-config-kafka_mirrormaker:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "kafka_mirrormaker" "includes/config-kafka_mirrormaker.rst"
service-type-config-kafka_connect:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "kafka_connect" "includes/config-kafka_connect.rst"
service-type-config-kafka:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "kafka" "includes/config-kafka.rst"
service-type-config-m3aggregator:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "m3aggregator" "includes/config-m3aggregator.rst"
service-type-config-m3db:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "m3db" "includes/config-m3db.rst"
service-type-config-mysql:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "mysql" "includes/config-mysql.rst"
service-type-config-opensearch:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "opensearch" "includes/config-opensearch.rst"
service-type-config-redis:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "redis" "includes/config-redis.rst"
service-type-config-influxdb:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "influxdb" "includes/config-influxdb.rst"
service_type_config-dragonfly:
python "$(SOURCEDIR)/scripts/aiven/service_type_config.py" "dragonfly" "includes/config-dragonfly.rst"
# TODO: add automation for "pg". See https://github.com/aiven/devportal/issues/1026
# (Re)Generate cloud listing
cloud-list:
python "$(SOURCEDIR)/scripts/aiven/clouds.py" "includes/clouds-list.rst"