Hello world example
$ juju bootstrap aws ctrl1
$ juju deploy mysql
$ juju offer mysql:db hosted-mysql
$ juju bootstrap aws ctrl2
$ juju deploy mediawiki
$ juju expose mediawiki
$ juju relate mediawiki:db ctrl1:admin/default.hosted-mysql
On the offering model, see what offers are and who is connected:
$ juju switch ctrl1
$ juju offers
You can also use permissions. People with consume permission can access an offer without having other rights to the model. On ctrl1:
$ juju grant fred consume admin/default.hosted-mysql
Now, if "fred" has login access to ctrl1, he can consume that offer.
You can also run these (see their --help)
$ juju find-endpoints
$ juju show-endpoints