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

Add logs to generate bundle #143

Merged
merged 9 commits into from
Sep 20, 2023
Merged

Conversation

elfiesmelfie
Copy link
Contributor

No description provided.

pushd "${REL}/../" > /dev/null 2>&1
${OPERATOR_SDK} generate bundle --channels ${BUNDLE_CHANNELS} --default-channel ${BUNDLE_DEFAULT_CHANNEL} --manifests --metadata --version "${OPERATOR_BUNDLE_VERSION}" --output-dir "${WORKING_DIR}" > /dev/null 2>&1
popd > /dev/null 2>&1
pushd "${REL}/../" >> ${LOGFILE} 2>&1
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are the pushd / popd logs actually useful?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Beats me, I'm trying to test whether I can use Depends-On with zuul. I have some additional changes to make in infrawatch/service-telemetry-operator#429 so that we can configure the destination dirs and not always try to clone the repos.

I'll have to check the usefulness of this output later

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh! They were useful when initially debugging, before I started using absolute dirs, since it was hard to tell where the commands were being executed.

elfiesmelfie added a commit to infrawatch/service-telemetry-operator that referenced this pull request Aug 29, 2023
@elfiesmelfie elfiesmelfie changed the title Add logs to generate bundle [WIP] Add logs to generate bundle Aug 29, 2023
elfiesmelfie added a commit to infrawatch/service-telemetry-operator that referenced this pull request Aug 31, 2023
elfiesmelfie added a commit to infrawatch/service-telemetry-operator that referenced this pull request Sep 1, 2023
elfiesmelfie added a commit to infrawatch/service-telemetry-operator that referenced this pull request Sep 1, 2023
elfiesmelfie added a commit to infrawatch/service-telemetry-operator that referenced this pull request Sep 1, 2023
elfiesmelfie added a commit to infrawatch/service-telemetry-operator that referenced this pull request Sep 1, 2023
elfiesmelfie added a commit to infrawatch/service-telemetry-operator that referenced this pull request Sep 4, 2023
@elfiesmelfie elfiesmelfie changed the title [WIP] Add logs to generate bundle Add logs to generate bundle Sep 13, 2023
pushd "${REL}/../" > /dev/null 2>&1
${OPERATOR_SDK} generate bundle --channels ${BUNDLE_CHANNELS} --default-channel ${BUNDLE_DEFAULT_CHANNEL} --manifests --metadata --version "${OPERATOR_BUNDLE_VERSION}" --output-dir "${WORKING_DIR}" > /dev/null 2>&1
popd > /dev/null 2>&1
pushd "${REL}/../" >> ${LOGFILE} 2>&1
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh! They were useful when initially debugging, before I started using absolute dirs, since it was hard to tell where the commands were being executed.


sed -i -E "${REPLACE_REGEX}" "${WORKING_DIR}/manifests/${OPERATOR_NAME}.clusterserviceversion.yaml"
}

copy_extra_metadata() {
pushd "${REL}/../" > /dev/null 2>&1
pushd "${REL}/../" >> ${LOGFILE} 2>&1
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll revert these lines, like in the STO generate_bundle.sh

@@ -42,6 +45,7 @@ build_bundle_instructions() {
}


${OPERATOR_SDK} version
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was definitely for debugging, and helped eventually to figure out that there were multiple operator-sdk versions needed

@@ -1,6 +1,9 @@
#!/usr/bin/env bash
set -e
REL=$(dirname "$0")
set -x
LOGFILE=${LOGFILE:-/dev/null}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I need to truncate this, in case there's already a logfile present

@elfiesmelfie
Copy link
Contributor Author

This change is checked by Jenkins in infrawatch/service-telemetry-operator#463

both branches are checked out and tested together

@elfiesmelfie elfiesmelfie merged commit 0f44c51 into master Sep 20, 2023
6 checks passed
@elfiesmelfie elfiesmelfie deleted the add_logs_to_generate_bundle branch September 20, 2023 11:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants