This repository has been archived by the owner on Jul 24, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
82 lines (53 loc) · 1.66 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
HELP_FUN = \
%help; while(<>){push@{$$help{$$2//'options'}},[$$1,$$3] \
if/^([\w-_]+)\s*:.*\#\#(?:@(\w+))?\s(.*)$$/}; \
print"$$_:\n", map" $$_->[0]".(" "x(20-length($$_->[0])))."$$_->[1]\n",\
@{$$help{$$_}},"\n" for keys %help; \
help: ##@Miscellaneous Show this help
@echo -e "Usage: make [target] ...\n"
@perl -e '$(HELP_FUN)' $(MAKEFILE_LIST)
#
#
# UPDATING TAR (usually from RedOS server)
#
#
remove_old_kernels: ##@Cleaning
dnf -y remove --oldinstallonly kernel || true
clean_dnf_cache: ##@Cleaning
dnf autoremove -y || true
dnf clean all
clean_python: ##@Cleaning python3 pip cache
python -m pip cache purge
clean_home: ##@Cleaning remove other caches
rm -rf ~/.cache
clean: clean_dnf_cache clean_python clean_home
update: ##@Update update system and some python packages
dnf update -y
mandb
python -m pip install --upgrade pip wheel setuptools cryptography
prepare: update clean ##@Update update packages and clean cache
pack:
bash ./tar-redos.sh
tar: pack ##@Update create new system tar
update-tar: prepare tar ##@Update perform system updates and archiving
#
#
# PUSHING (usually from other operation system what has access to tar)
#
#
dockerv: ##@Docker start Docker
sudo service docker start
scp: ##@Manage copy tar to remote server
bash ./scp.sh
load: ##@Docker load tar to Docker daemon
bash ./load.sh
push: ##@Docker push image to DockerHub
bash ./push.sh
release: load push ##@Docker load + push
#
#
# UTILS
#
#
run:
docker run -it redos73-base bash