Skip to content

Commit

Permalink
Merge pull request #13 from influxdb/fix-packaging
Browse files Browse the repository at this point in the history
Un-break the packaging script.
  • Loading branch information
toddboom committed Jun 20, 2015
2 parents 6566cc5 + 10bf663 commit 11a6db8
Showing 1 changed file with 2 additions and 11 deletions.
13 changes: 2 additions & 11 deletions package.sh
Original file line number Diff line number Diff line change
Expand Up @@ -171,15 +171,6 @@ do_build() {
echo "Build completed successfully."
}

# return a list of package dependencies for fpm
get_fpm_pkg_deps() {
local deps=" "
for d in ${PKG_DEPS[@]}; do
deps="${deps} -d '${d}'"
done
echo -n ${deps}
}

# generate_postinstall_script creates the post-install script for the
# package. It must be passed the version.
generate_postinstall_script() {
Expand Down Expand Up @@ -287,14 +278,14 @@ else
fi

COMMON_FPM_ARGS="-C $TMP_WORK_DIR --vendor $VENDOR --url $URL --license $LICENSE --maintainer $MAINTAINER --after-install $POST_INSTALL_PATH --name telegraf --version $VERSION --config-files $CONFIG_ROOT_DIR ."
$rpm_args fpm -s dir -t rpm $(get_fpm_pkg_deps) --description "$DESCRIPTION" $COMMON_FPM_ARGS
$rpm_args fpm -s dir -t rpm --description "$DESCRIPTION" $COMMON_FPM_ARGS
if [ $? -ne 0 ]; then
echo "Failed to create RPM package -- aborting."
cleanup_exit 1
fi
echo "RPM package created successfully."

fpm -s dir -t deb $deb_args $(get_fpm_pkg_deps) --description "$DESCRIPTION" $COMMON_FPM_ARGS
fpm -s dir -t deb $deb_args --description "$DESCRIPTION" $COMMON_FPM_ARGS
if [ $? -ne 0 ]; then
echo "Failed to create Debian package -- aborting."
cleanup_exit 1
Expand Down

0 comments on commit 11a6db8

Please sign in to comment.