Skip to content

OSE ceph examples#4772

Closed
jeffvance wants to merge 9 commits intoopenshift:masterfrom
jeffvance:ose_ceph_doc
Closed

OSE ceph examples#4772
jeffvance wants to merge 9 commits intoopenshift:masterfrom
jeffvance:ose_ceph_doc

Conversation

@jeffvance
Copy link

I've added several examples using ceph to persist a mysql database.

@smarterclayton
Copy link
Contributor

@bparees @mfojtik can you guys look over these?

Copy link
Contributor

Choose a reason for hiding this comment

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

this should use the openshift provided mysql image instead, which doesn't require any security changes to work....
https://github.com/openshift/mysql

@bparees
Copy link
Contributor

bparees commented Sep 23, 2015

my main concern is it doesn't use our openshift mysql image.

  1. that means more steps for users to setup for security
  2. if our image doesn't work for this example, we should fix it.

but for a detailed review of the actual steps/instructions, this seems better suited to the storage team.. @markturansky @eparis ?

@markturansky
Copy link
Member

Two things:

  1. I agree with Ben that this can use our own MySQL image. See the WordPress example: https://github.com/openshift/origin/blob/master/examples/wordpress/pod-mysql.yaml

(1a -- Ben, if your team could make a WordPress image that didn't require root/port 80, the WordPress example becomes simpler by removing the security caveats from the readme).

  1. @jsafrane has a PR (RFC: refactor persistent storage example and add Cinder documentation #4403) that re-uses the WordPress example and shows how you can swap out storage beneath. The overall example is the same.

I prefer Jan's approach. I think this ceph example should re-use our WordPress stuff. This PR could add a 3rd volume to the example (NFS was first, Jan added Cinder, this PR can add Ceph).

@markturansky
Copy link
Member

Also, I know nothing of Ceph, so I leave detailed steps/instructions review to @rootfs who wrote the Ceph plugin and upstream readme.

@jeffvance
Copy link
Author

I will redo the example to fit under the wordpress umbrella. Using Jan's wordpress readme, I'll add a ceph bullet under the "Storage Provisioning" header.

@bparees
Copy link
Contributor

bparees commented Sep 23, 2015

@markturansky shockingly enough, this actually worked:

# create a mysql db service (in this case using ephemeral storage but obviously you can set it up however you like)
$ oc new-app mysql-ephemeral

# create a new app using our s2i php builder and the wordpress github repo
$ oc new-app https://github.com/wordpress/wordpress

Then connect to the wordpress service via your web browser. you'll need to supply the mysql user/password/dbname/service ip as part of the setup. (the user/pass/dbname generated by the template as env variables)

@markturansky
Copy link
Member

that's very cool :)

On Wed, Sep 23, 2015 at 3:50 PM, Ben Parees notifications@github.com
wrote:

@markturansky https://github.com/markturansky shockingly enough, this
actually worked:
create a mysql db service (in this case using ephemeral storage but
obviously you can set it up however you like)

$ oc new-app mysql-ephemeral
create a new app using our s2i php builder and the wordpress github repo

$ oc new-app https://github.com/wordpress/wordpress

Then connect to the wordpress service via your web browser. you'll need to
supply the mysql user/password/dbname/service ip as part of the setup. (the
user/pass/dbname generated by the template as env variables)


Reply to this email directly or view it on GitHub
#4772 (comment).

@mfojtik
Copy link
Contributor

mfojtik commented Sep 24, 2015

@mnagy fyi

Copy link
Member

Choose a reason for hiding this comment

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

echo -n

@danmcp
Copy link

danmcp commented Oct 16, 2015

@jeffvance Needs to be squashed after the comments are addressed.

@openshift-bot openshift-bot added needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Oct 22, 2015
Copy link
Contributor

Choose a reason for hiding this comment

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

This is no longer needed with the version of kubernetes that we bundle.

Copy link
Contributor

Choose a reason for hiding this comment

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

you can use "mysql" as <mysql-container-ID>, as you set the container name with docker run --name mysql

@jsafrane
Copy link
Contributor

jsafrane commented Nov 4, 2015

To be honest, I do not like the guide. As pointed out by others,it does not use OpenShift mysql and the structure is confusing.

  • What is ceph-examples/MYSQL.md good for? Neither of the steps there are needed to deploy mysql on Ceph RBD and they are not Ceph specific at all.
  • ceph-examples/mysql_ceph_host does cover Ceph at all, there should be separate example for host_path volumes
  • there is lot of redundant information in ceph-examples/mysql_ceph_plugin, mysql_ceph_pvc and mysql_ceph_template chapters. What about one chap. for introduction + preparation, three chapters for pv/pvc/pod creation with only the specific information and one last chapter for checking mysql / cleanup?

And.. will be have three different examples (volume directly in a pod, PV+PVC and application template) for all volume plugins? IMo it would make more sense to teach admins just how to create a PV (= one example for each plugin) + one common example how to use them with a PVC or application template? Because the PVC and the template will be always the same, regardless which volume plugin is used.

I already started with that in https://github.com/openshift/origin/tree/master/examples/wordpress
(patches welcome, I am neither writer nor native speaker, I like your attention to SELinux and security details)

@openshift-bot openshift-bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Nov 13, 2015
@openshift-bot
Copy link
Contributor

Origin Action Required: Pull request cannot be automatically merged, please rebase your branch from latest HEAD and push again

@openshift-bot openshift-bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Nov 13, 2015
@danmcp
Copy link

danmcp commented Jan 18, 2016

Closing due to age and inactivity.

@danmcp danmcp closed this Jan 18, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants