File tree Expand file tree Collapse file tree 1 file changed +18
-2
lines changed
Expand file tree Collapse file tree 1 file changed +18
-2
lines changed Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ if [[ ! -z ${CERT} ]] && [[ ! -z ${KEY} ]]; then
3434fi
3535
3636if [[ -z ${PKG_REPO} ]]; then
37- echo " defaulting to packages.nginx.com "
37+ echo " defaulting to packages.nginx.org "
3838 PKG_REPO=" packages.nginx.org"
3939fi
4040
@@ -44,7 +44,6 @@ if [[ -z $VERSION ]]; then
4444 echo " no version provided"
4545 exit 1
4646fi
47-
4847PKG_DIR=" ${PKG_REPO} /${PKG_NAME} "
4948PKG_REPO_URL=" https://${PKG_DIR} "
5049
@@ -93,6 +92,11 @@ CENTOS=(
9392 centos/8/x86_64/RPMS/nginx-agent-$VERSION .el8.ngx.x86_64.rpm
9493)
9594
95+ FREEBSD=(
96+ freebsd/FreeBSD:12:amd64/latest/nginx-agent-$VERSION .pkg
97+ freebsd/FreeBSD:13:amd64/latest/nginx-agent-$VERSION .pkg
98+ )
99+
96100uris=(
97101 ${DEBIAN[@]}
98102 ${UBUNTU[@]}
@@ -102,6 +106,13 @@ uris=(
102106 ${SUSE[@]}
103107)
104108
109+ majorVersion=$( echo ${VERSION} | cut -d. -f1)
110+ if [[ ${majorVersion} == 2 ]]; then
111+ uris+=(${FREEBSD[@]} )
112+ fi
113+
114+ # Functions
115+
105116# # Check and download if nginx-agent packages are present in the repository
106117check_pkgs () {
107118 for pkg in ${uris[@]} ; do
@@ -156,7 +167,12 @@ check_repo() {
156167 else
157168 echo -e " ${GREEN} Found!${NC} "
158169 fi
170+
171+ # Grep index.xml for all supported operating system versions
172+
159173}
160174
175+ # Main
176+
161177check_repo
162178check_pkgs
You can’t perform that action at this time.
0 commit comments