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

update supported arches for kn-workflow-cli-artifacts image #36

Merged
merged 7 commits into from
Jun 4, 2024

Conversation

rgdoliveira
Copy link
Member

@rgdoliveira rgdoliveira commented May 6, 2024

As discussed in slack channel, for kn cli we should only support amd64 and aarch64, IBM P/Z is not supported and there will be no rpm build of it.

Related PRs:

Checklist

  • Add or Modify a unit test for your change
  • Have you verified that tall the tests are passing?
How to backport a pull request to a different branch?

In order to automatically create a backporting pull request please add one or more labels having the following format backport-<branch-name>, where <branch-name> is the name of the branch where the pull request must be backported to (e.g., backport-7.67.x to backport the original PR to the 7.67.x branch).

NOTE: backporting is an action aiming to move a change (usually a commit) from a branch (usually the main one) to another one, which is generally referring to a still maintained release branch. Keeping it simple: it is about to move a specific change or a set of them from one branch to another.

Once the original pull request is successfully merged, the automated action will create one backporting pull request per each label (with the previous format) that has been added.

If something goes wrong, the author will be notified and at this point a manual backporting is needed.

NOTE: this automated backporting is triggered whenever a pull request on main branch is labeled or closed, but both conditions must be satisfied to get the new PR created.

@rgdoliveira
Copy link
Member Author

rgdoliveira commented May 6, 2024

As discussed on slack channel, the kn workflow rpm will be built for x86_64 and aarch64 only, IBM Z and P are not required.

@rgdoliveira
Copy link
Member Author

Thanks for approving it, I will just wait for the rpm part to be built and then I can merge this one (or change something if required)

@domhanak domhanak self-requested a review May 29, 2024 06:39
tar --transform='flags=r;s|kn-workflow-darwin-amd64|kn|' -zcf kn-workflow-macos-amd64.tar.gz kn-workflow-darwin-amd64 LICENSE
tar --transform='flags=r;s|kn-workflow-darwin-arm64|kn|' -zcf kn-workflow-macos-arm64.tar.gz kn-workflow-darwin-arm64 LICENSE

mkdir "${KN_WORK_DIR}/windows" && mv kn-workflow-windows-amd64.exe "${KN_WORK_DIR}/windows/kn.exe" && cp LICENSE "${KN_WORK_DIR}/windows/" && zip --quiet --junk-path - "${KN_WORK_DIR}/windows/*" > kn-workflow-windows-amd64.zip
Copy link
Member Author

@rgdoliveira rgdoliveira Jun 3, 2024

Choose a reason for hiding this comment

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

The image is failing to build in this part related to Windows and it seems it is failing when invoking the zip command.
@ricardozanini could you please take a look at it? I sent in slack the command to build the image with correct URL.

Copy link
Member

Choose a reason for hiding this comment

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

What's the error?

Copy link
Member Author

Choose a reason for hiding this comment

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

+ mkdir /opt/app-root/src/go/src/github.com/knative/client/windows
+ mv kn-workflow-windows-amd64.exe /opt/app-root/src/go/src/github.com/knative/client/windows/kn.exe
+ cp LICENSE /opt/app-root/src/go/src/github.com/knative/client/windows/
+ zip --quiet --junk-path - '/opt/app-root/src/go/src/github.com/knative/client/windows/*'

zip error: Nothing to do! (-)
Error: building at STEP "RUN sh -x /tmp/scripts/com.redhat.osl.cli.packager/install.sh": while running runtime: exit status 12
2024-06-03 18:55:32,012 tools.py:359        ERROR Command '['/usr/bin/podman', 'build', '--squash', '-t', 'openshift-serverless-1/logic-kn-workflow-cli-artifacts-rhel8:1.33.0', '-t', 'openshift-serverless-1/logic-kn-workflow-cli-artifacts-rhel8:latest', '--build-arg=KN_ARTIFACT_URL=http://download.devel.redhat.com/staging-cds/etera/test/kn-workflow-plugin/1/1.33/1.33.0-1/signed/', 'target/image']' returned non-zero exit status 12. Command stdout is 'None' with stderr 'None'
2024-06-03 18:55:32,012 cli.py:542        ERROR Could not run podman ['/usr/bin/podman', 'build', '--squash', '-t', 'openshift-serverless-1/logic-kn-workflow-cli-artifacts-rhel8:1.33.0', '-t', 'openshift-serverless-1/logic-kn-workflow-cli-artifacts-rhel8:latest', '--build-arg=KN_ARTIFACT_URL=http://download.devel.redhat.com/staging-cds/etera/test/kn-workflow-plugin/1/1.33/1.33.0-1/signed/', 'target/image']
Traceback (most recent call last):
  File "/home/rguimara/cekit-4.11.0/lib64/python3.11/site-packages/cekit/tools.py", line 351, in run_wrapper
    result = subprocess.run(
             ^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/subprocess.py", line 571, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['/usr/bin/podman', 'build', '--squash', '-t', 'openshift-serverless-1/logic-kn-workflow-cli-artifacts-rhel8:1.33.0', '-t', 'openshift-serverless-1/logic-kn-workflow-cli-artifacts-rhel8:latest', '--build-arg=KN_ARTIFACT_URL=http://download.devel.redhat.com/staging-cds/etera/test/kn-workflow-plugin/1/1.33/1.33.0-1/signed/', 'target/image']' returned non-zero exit status 12.

@rgdoliveira
Copy link
Member Author

thanks, merging it.

@rgdoliveira rgdoliveira merged commit be4873d into kiegroup:main Jun 4, 2024
4 checks passed
rgdoliveira added a commit that referenced this pull request Jun 4, 2024
* update supported arches for kn-workflow-cli-artifacts image

* set versions to 1.33.0

* fix indentation in images/osl-cli.yaml

* fix LICENSE path in /tmp

* add quiet to wget

* fix zip command when creating windows zip

* remove internal url from example
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants