Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: Install dd-pkg in *-verify workflows and lint in verify-install.sh #20397

Merged
merged 1 commit into from
Apr 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -347,6 +347,7 @@ jobs:
- build-x86_64-unknown-linux-gnu-packages
env:
VECTOR_VERSION: ${{ needs.generate-publish-metadata.outputs.vector_version }}
DD_PKG_VERSION: "latest"
strategy:
matrix:
container:
Expand All @@ -369,6 +370,9 @@ jobs:
git \
systemd \
make
- name: Install dd-pkg for linting
run: |
curl -sSL "https://dd-package-tools.s3.amazonaws.com/dd-pkg/${DD_PKG_VERSION}/dd-pkg_Linux_x86_64.tar.gz" | tar -xz -C /usr/local/bin dd-pkg
- name: Fix Git safe directories issue when in containers (actions/checkout#760)
run: git config --global --add safe.directory /__w/vector/vector
- name: Checkout Vector
Expand All @@ -393,6 +397,7 @@ jobs:
- build-x86_64-unknown-linux-gnu-packages
env:
VECTOR_VERSION: ${{ needs.generate-publish-metadata.outputs.vector_version }}
DD_PKG_VERSION: "latest"
strategy:
matrix:
container:
Expand All @@ -419,6 +424,9 @@ jobs:
if ! command -v curl &> /dev/null ; then
yum install -y curl
fi
- name: Install dd-pkg for linting
run: |
curl -sSL "https://dd-package-tools.s3.amazonaws.com/dd-pkg/${DD_PKG_VERSION}/dd-pkg_Linux_x86_64.tar.gz" | tar -xz -C /usr/local/bin dd-pkg
- name: Fix Git safe directories issue when in containers (actions/checkout#760)
run: git config --global --add safe.directory /__w/vector/vector
- name: Checkout Vector
Expand Down
4 changes: 3 additions & 1 deletion scripts/verify-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ set -euo pipefail
#
# SUMMARY
#
# Verifies vector packages have been installed correctly
# Verifies vector packages have been built and installed correctly

package="${1:?must pass package as argument}"

Expand Down Expand Up @@ -38,3 +38,5 @@ getent group vector || (echo "vector group missing" && exit 1)
vector --version || (echo "vector --version failed" && exit 1)
grep -q "FOO=bar" "/etc/default/vector" || (echo "/etc/default/vector has incorrect contents" && exit 1)
grep -q "foo: bar" "/etc/vector/vector.yaml" || (echo "/etc/vector/vector.yaml has incorrect contents" && exit 1)

dd-pkg lint "$package"
Loading