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 ppc64le & multiarch support #136

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

sdmonov
Copy link

@sdmonov sdmonov commented Sep 13, 2018

This code is adding ppc64le and multiarch support for FfDL.

  • Adds new make target to the main Makefile: docker-create-manifest
    that creates the multiarch manifests for the services.

  • arch (architecture) parameter was added to values.yaml and
    storage-plugin/values.yaml

make docker-build will generate all the services with a -${ARCHITECTURE}
suffix. During build an ARCH argument is sent to the Dockerfiles in order
to have architecture specific implementation inside it.

Building docker images for ppc64le should look like this:

make docker-build
make docker-push
make docker-create-manifest
.....
helm install storage-plugin --set arch=ppc64le,namespace=$NAMESPACE
helm install . --set arch=ppc64le,lcm.shared_volume_storage_class=$SHARED_VOLUME_STORAGE_CLASS,namespace=$NAMESPACE

Fixes #115

Developer's Certificate of Origin 1.1

   By making a contribution to this project, I certify that:

   (a) The contribution was created in whole or in part by me and I
       have the right to submit it under the Apache License 2.0; or

   (b) The contribution is based upon previous work that, to the best
       of my knowledge, is covered under an appropriate open source
       license and I have the right under that license to submit that
       work with modifications, whether created in whole or in part
       by me, under the same open source license (unless I am
       permitted to submit under a different license), as indicated
       in the file; or

   (c) The contribution was provided directly to me by some other
       person who certified (a), (b) or (c) and I have not modified
       it.

   (d) I understand and agree that this project and the contribution
       are public and that a record of the contribution (including all
       personal information I submit with it, including my sign-off) is
       maintained indefinitely and may be redistributed consistent with
       this project or the open source license(s) involved.

This code is adding ppc64le and multiarch support for FfDL.

- Adds new make target to the main Makefile: **docker-create-manifest**
  that creates the multiarch manifests for the services.

- arch (architecture) parameter was added to values.yaml and
  storage-plugin/values.yaml

**make docker-build** will generate all the services with a -${ARCHITECTURE}
suffix. During build an ARCH argument is sent to the Dockerfiles in order
to have architecture specific implementation inside it.

Building docker images should look like this:

make docker-build
make docker-push
make docker-create-manifest
@sdmonov
Copy link
Author

sdmonov commented Sep 13, 2018

Hi All,

This code adds support for ppc64le in FfDL. It does adds a suffix to the built services with the architecture and also adds a target in the main Makefile to create/ammend the needed manifest lists to support the multiple architectures.

There are two services that are needed by the code prom/pushgateway and localstack/localstack (optional) that does not have a ppc64le version in the public registries. I did generate custom build ppc64le version and pushed it to my own registry smonov. They will be pulled from there for now until published on a more official registry.

values.yaml Outdated
services:
expose_node_port: true
docker:
registry: docker.io
registry: ffdl.ibm.com
Copy link
Contributor

Choose a reason for hiding this comment

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

This changes our official Docker image location.

Copy link
Author

Choose a reason for hiding this comment

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

Sorry my mistake. This was not supposed to be there. Will fix it.

@sdmonov
Copy link
Author

sdmonov commented Sep 14, 2018

Found few issues. Fixing and testing them now:

  • fixed issue with the repository in the values.yaml reported by @Tomcli
  • added new target to the Makefile: docker-tag-local. It will tag the arch dependent image name to arch independent name. For example: ffdl/ffdl-ui-ppc64le:v0.1.1 will be tagged to ffdl/ffdl-ui:v.0.1.1. This is used for local deployments only that do not require pushing to registry. make docker-push will push only the arch dependent images (with -${ARCHITECTURE} suffix) only and then a manifest lists will be created for these image to support multiarch (by invoking make docker-create-manifest).
  • updated .travis.yml to invoke docker-tag-local.

@animeshsingh
Copy link

Thanks @sdmonov. What is the target for travis if any?

@seelam
Copy link

seelam commented Sep 14, 2018

helm install storage-plugin --set arch=ppc64le,namespace=$NAMESPACE
What if you have a mixed x86, POWER cluster, what happens then?

Could we not put the multi-arch storage plugin in a private repo and use it?

The public travis ci is now multi-arch so you should do builds with it. I would like to see the changes in Travis.yaml file.

We have to deal with learner images... is that addressed in a different PR?

- added docker-tag-local target in Makefile
- fixed few issues in docker-create-manifest target in Makefile
- small fix in docker-push to not have duplicate code
@sdmonov
Copy link
Author

sdmonov commented Sep 17, 2018

@seelam:

  • About the storage plugin I totally agree with you we need to push multi-arch images and create a manifest list. I have no access to push images at the moment. If I can be given access (@animeshsingh) I can push both ppc64le and x86_64 images and create the manifest lists to support the multi-arch.
  • at the moment travil.yml (as far as I can tell looking into it) is doing testing only. It is not pushing images to the repos
  • learner images will go separate PR. will commit soon.

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.

Power support in FfDL
4 participants