-
Notifications
You must be signed in to change notification settings - Fork 21
/
Copy pathMakefile
67 lines (60 loc) · 2.49 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
# @copyright Copyright (c) 2022 Arthur Schiwon <[email protected]>
#
# @author Arthur Schiwon <[email protected]>
#
# @license GNU AGPL app_version 3 or any later app_version
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either app_version 3 of the
# License, or (at your option) any later app_version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
app_name=nextcloud
app_version=28.0.14-0
app_upgrade_from=27.1.6-0
ucs_version=5.0
docker_repo=nextcloud
docker_login=`cat ~/.docker-account-user`
docker_pwd=`cat ~/.docker-account-pwd`
.PHONY: all
all: push-files docker
.PHONY: add-version
add-version:
if [ -z ${app_ver} ] ; then echo "no original app_version specified"; exit 13; fi
if [ -z ${app_newver} ] ; then echo "no target app_version specified"; exit 13; fi
univention-appcenter-control new-version "$(ucs_version)/$(app_name)=$(app_ver)" "$(ucs_version)/$(app_name)=$(app_newver)"
.PHONY: push-files
push-files:
univention-appcenter-control upload --noninteractive $(ucs_version)/$(app_name)=$(app_version) \
attributes \
env \
restore_data_before_setup \
setup \
restore_data_after_setup \
preinst \
inst \
store_data \
uinst \
update_app_version \
nextcloud.schema \
i18n/en/README_INSTALL_EN \
i18n/de/README_INSTALL_DE \
i18n/en/README_POST_INSTALL_EN \
i18n/de/README_POST_INSTALL_DE \
i18n/en/README_UNINSTALL_EN \
i18n/de/README_UNINSTALL_DE \
i18n/en/README_POST_UPDATE_EN \
i18n/de/README_POST_UPDATE_DE
univention-appcenter-control set --noninteractive $(ucs_version)/$(app_name)=$(app_version) \
--json '{"DockerImage": "ghcr.io/nextcloud/univention-app:$(app_version)", "UMCOptionsAttributes": "nextcloudEnabled", "WebInterface": "/nextcloud", "MinPhysicalRam": "512", "RequiredUcsVersion": "5.0-0", "SupportedUCSVersions": "5.0-0", "RequiredAppVersionUpgrade": "$(app_upgrade_from)"}'
.PHONY: docker
docker:
if [ `systemctl is-active docker` = "inactive" ] ; then sudo systemctl start docker; fi
sudo docker build -t $(docker_repo)/univention-app:$(app_version) .