-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
45 lines (38 loc) · 1.69 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
SHELL := /bin/bash
PROJECT_ID := datainasafeorg
# ----------------------------------------------------------------------------
# P R O D U C T I O N C O M M A N D S
# ----------------------------------------------------------------------------
default: deploy
build:
@echo
@echo "------------------------------------------------------------------"
@echo "Building in production mode"
@echo "------------------------------------------------------------------"
@docker-compose -p $(PROJECT_ID) build
deploy: build
@echo
@echo "------------------------------------------------------------------"
@echo "Bringing up fresh instance "
@echo "You can access it on http://localhost:8190"
@echo "------------------------------------------------------------------"
@docker-compose -p $(PROJECT_ID) up -d btsync
@docker-compose -p $(PROJECT_ID) up -d apache
backup:
@echo
@echo "------------------------------------------------------------------"
@echo "Backing up data"
@echo "------------------------------------------------------------------"
@docker exec -t -i $(PROJECT_ID)_sftpbackup_1 /backups.sh
pushbackup:
@echo
@echo "------------------------------------------------------------------"
@echo "Push local backup in sftpbackup to sftp remote server"
@echo "------------------------------------------------------------------"
@docker exec -t -i $(PROJECT_ID)_sftpbackup_1 /start.sh push-to-remote-sftp
pullbackup:
@echo
@echo "------------------------------------------------------------------"
@echo "Pull remote sftp backup to local backup"
@echo "------------------------------------------------------------------"
@docker exec -t -i $(PROJECT_ID)_sftpbackup_1 /start.sh pull-from-remote-sftp