-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
162 lines (143 loc) · 5.45 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
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
RUST_VERSION = $(shell cat .rust-version)
run_alisa: RUST_LOG = alisa=debug,info
run_alisa: JWT_SECRET = 123456
run_alisa: LISA_USER = chipp
run_alisa: LISA_PASSWORD = kek
run_alisa: ALICE_SKILL_ID = $(shell op read "op://private/yandex.alisa/username" -n)
run_alisa: ALICE_TOKEN = $(shell op read "op://private/yandex.alisa/credential" -n)
run_alisa: MQTT_ADDRESS = mqtt://localhost:1883
run_alisa: MQTT_USER = alisa
run_alisa: MQTT_PASS = 123mqtt
run_alisa:
@RUST_LOG=${RUST_LOG} JWT_SECRET=${JWT_SECRET} \
LISA_USER=${LISA_USER} LISA_PASSWORD=${LISA_PASSWORD} \
ALICE_SKILL_ID=${ALICE_SKILL_ID} ALICE_TOKEN=${ALICE_TOKEN} \
MQTT_ADDRESS=${MQTT_ADDRESS} MQTT_USER=${MQTT_USER} MQTT_PASS=${MQTT_PASS} \
cargo run --bin alisa
build_alisa: IMAGE_ID = ghcr.io/chipp/alisa
build_alisa:
docker build . \
--file bin/alisa/Dockerfile \
--tag ${IMAGE_ID}:test \
--build-arg RUST_VERSION="${RUST_VERSION}" \
--load \
--label "org.opencontainers.image.source=https://github.com/chipp/lisa" \
--cache-from=type=registry,ref=${IMAGE_ID}:cache
docker run --rm -v "${PWD}/build:/build" \
${IMAGE_ID}:test \
cp /root/alisa /build/alisa
docker build . \
--file conf/arm64.Dockerfile \
--load \
--platform linux/arm64 \
--progress plain \
--tag ${IMAGE_ID}:latest \
--build-arg BINARY=alisa \
--label "org.opencontainers.image.source=https://github.com/chipp/lisa"
run_elizabeth: RUST_LOG = elizabeth=debug,info
run_elizabeth: MQTT_ADDRESS = mqtt://localhost:1883
run_elizabeth: MQTT_USER = elizabeth
run_elizabeth: MQTT_PASS = 123mqtt
run_elizabeth: INSPINIA_CLIENT_ID = $(shell op read "op://private/inspinia test/username" -n)
run_elizabeth: INSPINIA_TOKEN = $(shell op read "op://private/inspinia test/credential" -n)
run_elizabeth: INSPINIA_LOGS_PATH = ${PWD}/logs
run_elizabeth:
@RUST_LOG=${RUST_LOG} INSPINIA_LOGS_PATH=${INSPINIA_LOGS_PATH} \
MQTT_ADDRESS=${MQTT_ADDRESS} MQTT_USER=${MQTT_USER} MQTT_PASS=${MQTT_PASS} \
INSPINIA_CLIENT_ID=${INSPINIA_CLIENT_ID} INSPINIA_TOKEN=${INSPINIA_TOKEN} \
cargo run --bin elizabeth
build_elizabeth: IMAGE_ID = ghcr.io/chipp/elizabeth
build_elizabeth:
docker build . \
--file bin/elizabeth/Dockerfile \
--tag ${IMAGE_ID}:test \
--build-arg RUST_VERSION="${RUST_VERSION}" \
--load \
--label "org.opencontainers.image.source=https://github.com/chipp/lisa" \
--cache-from=type=registry,ref=${IMAGE_ID}:cache
docker run --rm -v "${PWD}/build:/build" \
${IMAGE_ID}:test \
cp /root/elizabeth /build/elizabeth
docker build . \
--file conf/arm64.Dockerfile \
--load \
--platform linux/arm64 \
--progress plain \
--tag ${IMAGE_ID}:latest \
--build-arg BINARY=elizabeth \
--label "org.opencontainers.image.source=https://github.com/chipp/lisa"
run_elisa: RUST_LOG = elisa=debug,info
run_elisa: MQTT_ADDRESS = mqtt://localhost:1883
run_elisa: MQTT_USER = elisa
run_elisa: MQTT_PASS = 123mqtt
run_elisa: VACUUM_IP = 10.0.1.150
run_elisa: VACUUM_TOKEN = $(shell op read "op://private/vacuum/credential" -n)
run_elisa:
@RUST_LOG=${RUST_LOG} VACUUM_IP=${VACUUM_IP} VACUUM_TOKEN=${VACUUM_TOKEN} \
MQTT_ADDRESS=${MQTT_ADDRESS} MQTT_USER=${MQTT_USER} MQTT_PASS=${MQTT_PASS} \
cargo run --bin elisa
build_elisa: IMAGE_ID = ghcr.io/chipp/elisa
build_elisa:
docker build . \
--file bin/elisa/Dockerfile \
--tag ${IMAGE_ID}:test \
--build-arg RUST_VERSION="${RUST_VERSION}" \
--load \
--cache-from=type=registry,ref=${IMAGE_ID}:cache
docker run --rm -v "${PWD}/build:/build" \
${IMAGE_ID}:test \
cp /root/elisa /build/elisa
run_isabel: RUST_LOG = isabel=debug,info
run_isabel: DB_PATH = ${PWD}/target/isabel.db
run_isabel: MQTT_ADDRESS = mqtt://localhost:1883
run_isabel: MQTT_USER = isabel
run_isabel: MQTT_PASS = 123mqtt
run_isabel:
@RUST_LOG=${RUST_LOG} DB_PATH=${DB_PATH} \
MQTT_ADDRESS=${MQTT_ADDRESS} MQTT_USER=${MQTT_USER} MQTT_PASS=${MQTT_PASS} \
cargo run --bin isabel
build_isabel: IMAGE_ID = ghcr.io/chipp/isabel
build_isabel:
docker build . \
--file bin/isabel/Dockerfile \
--tag ${IMAGE_ID}:test \
--build-arg RUST_VERSION="${RUST_VERSION}" \
--load \
--cache-from=type=registry,ref=${IMAGE_ID}:cache
docker run --rm -v "${PWD}/build:/build" \
${IMAGE_ID}:test \
cp /root/isabel /build/isabel
test_isabel_libs_amd64: IMAGE_ID = ghcr.io/chipp/isabel
test_isabel_libs_amd64:
docker build . \
--file bin/isabel/test_libs/amd64.Dockerfile \
--tag ${IMAGE_ID}:test_libs_amd64 \
--build-arg RUST_VERSION="${RUST_VERSION}" \
--load
test_isabel_libs_arm64: IMAGE_ID = ghcr.io/chipp/isabel
test_isabel_libs_arm64:
docker build . \
--file bin/isabel/test_libs/arm64.Dockerfile \
--tag ${IMAGE_ID}:test_libs_arm64 \
--build-arg RUST_VERSION="${RUST_VERSION}" \
--load
run_elisheba: RUST_LOG = elisheba=debug,sonoff=debug,info
run_elisheba: KEYS = 10020750eb=$(shell op read "op://private/elisheba devices/10020750eb"),1002074ed2=$(shell op read "op://private/elisheba devices/1002074ed2")
run_elisheba: MQTT_ADDRESS = mqtt://localhost:1883
run_elisheba: MQTT_USER = elisheba
run_elisheba: MQTT_PASS = 123mqtt
run_elisheba:
@RUST_LOG=${RUST_LOG} KEYS='${KEYS}' \
MQTT_ADDRESS=${MQTT_ADDRESS} MQTT_USER=${MQTT_USER} MQTT_PASS=${MQTT_PASS} \
cargo run --bin elisheba
build_elisheba: IMAGE_ID = ghcr.io/chipp/elisheba
build_elisheba:
docker build . \
--file bin/elisheba/Dockerfile \
--tag ${IMAGE_ID}:test \
--build-arg RUST_VERSION="${RUST_VERSION}" \
--load \
--cache-from=type=registry,ref=${IMAGE_ID}:cache
docker run --rm -v "${PWD}/build:/build" \
${IMAGE_ID}:test \
cp /root/elisheba /build/elisheba