-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathMakefile
47 lines (40 loc) · 1.4 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
all-golang:
cd webserver && make webserver && cd ..
cd api && make afn-rest-32 && cd ..
cd api && make afn-rest-64 && cd ..
client-dist.tgz:
make client/dist
echo "Press any key to launch archive build." && read dummy
tar -C client/ -cvzf client-dist.tgz dist/
client/dist:
mkdir client/dist
AFN_BUILD_DIR=client/dist/ bash afn-app.sh
client/fully-static:
make client/dist
mkdir -p client/fully-static/
cp -rp client/dist/* client/fully-static/
# news
mkdir -p client/fully-static/news
cp client/fully-static/site/news.html client/fully-static/news/index.html
cp client/fully-static/site/news.html client/fully-static/news.html
# faq
mkdir -p client/fully-static/faq
cp client/fully-static/site/faq.html client/fully-static/faq/index.html
cp client/fully-static/site/faq.html client/fully-static/faq.html
# help-translate
mkdir -p client/fully-static/help-translate
cp client/fully-static/site/help_translate.html client/fully-static/help-translate/index.html
cp client/fully-static/site/help_translate.html client/fully-static/help-translate.html
# app
mkdir -p client/fully-static/app
cp client/fully-static/app.html client/fully-static/app/index.html
clean:
rm -fr client/dist
rm -fr client/fully-static/
rm -f client-dist.tgz
.PHONY : deploy
deploy:
make clean
make build && \
scp afn.tgz [email protected]: && \
ssh [email protected] '/root/afn-utils/deploy_afn.sh production /root/afn.tgz'