• I have a small, JetPack enabled multisite install and would like to automatically connect all new sites created on my network to a single wordpress.com account. I have just three Jetpack modules enabled across my network – Protect, Stats & ShareDaddy.

    Currently I manually connect each new site to wordpress.com via my super admin account (Network Admin > Jetpack).

    Is it possible to automatically connect a new site to wordpress.com upon site creation? If so, how might this be achieved? Via a filter or wp-config definition perhaps?

    what are the implications of all my network sites being associated with a single wordpress.com account?

    Many thanks.

    https://www.ads-software.com/plugins/jetpack/

Viewing 13 replies - 1 through 13 (of 13 total)
  • network enable Jetpack on your multisite installation and activate the Protect feature on the network’s primary site. Once completed, Jetpack’s Protect feature will be activated on every site on your network, even if Jetpack isn’t connected on those sites.

    https://jetpack.me/support/multisite-protect/

    Thread Starter IstanbulMMV

    (@istanbulmmv)

    Many thanks for the suggestion – I wasn’t aware of that particular feature of Protect. JetPack is network enabled on my install and active on my primary site. Unfortunately without connecting each individual site to wordpress.com I can’t unlock ShareDaddy, Stats and theming tools (Featured Content, Site Logo, Responsive Videos). Auto-enabling these features would smooth the deployment of my sites considerably. Thanks again for the heads up.

    Hi – what happens when you change
    Sub-site override
    in network admin Jetpack Settings?

    I’m not sure if that forces the primary site connection or no connection at all

    I think Jetpack is a work in progress and isn’t really as complete and integrated as it should be (or hopefully will be)

    Hi – what happens when you change
    Sub-site override
    in network admin Jetpack Settings?

    I tried that and it doesn’t force a connection. It also keeps users from reconnecting using their own WordPress account, so not a great solution even if it did work.

    Jetpack… it’s a Semi-Automattic Airline…

    You’re asking a very good question so I don’t want to hijack any potential answers, I doubt jetpack support will offer a solution but worth trying maybe

    Thread Starter IstanbulMMV

    (@istanbulmmv)

    @nachoman42 & @wasanajones thank you both for your help/suggestions. Changing the sub-site override setting doesn’t solve my issue unfortunately. I actually already have this option set as I would like all sites to be associated with a single wordpress.com account so users don’t have to create their own wp.com profile. I’ll drop a note to the JetPack team and see how I get on. Thanks again.

    another element to this is to disable the notice that shows up in admin about jetpack centralized management. people click that without thinking about it. I had a client with all kinds of questions issues that took me a while to figure out what was going on – they were on wordpress.com rather than our network and didn’t even know it

    Looking at the class.jetpack-network.php in the plugin files and with some trial and error, the following seems to work:

    1. set user to network admin (needed when making connection)
    2. init Jetpack_Network class
    3. call do_subsiteregister function
    $id = wpmu_create_blog(...); // or some other method to get id of new blog
    $adminuser = get_user_by('login', 'admin'); // network admin user_id is probably 1, but just in you want to auto-connect based on a different user
    wp_set_current_user($adminuser->ID);
    $jetpack_network = Jetpack_Network::init();
    $jetpack_network->do_subsiteregister($id);

    This is working for me. I have included it in a plugin that creates new users & blogs.

    Plugin Author Jeremy Herve

    (@jeherve)

    Jetpack Mechanic ??

    That’s not possible right now, but I agree it’d be nice to add such an option to the Network admin screen. We’ll work on that!

    Feel free to subscribe to the issue I just created if you want to follow our progress on this:
    https://github.com/Automattic/jetpack/issues/2380

    I’ll also post again here as soon as I have some news.

    Thanks for the feedback!

    Thread Starter IstanbulMMV

    (@istanbulmmv)

    A very big thank you to all for their input on this question.

    If you follow the Github link that Jeremy posted above a temporary fix is offered by Brandon Kraft (kraftbj). By uncommenting the piece of code referenced by kraftbj in “views > admin > network settings” all new sites created on my network are now automatically connected to wordpress.com via a single wp.com account.

    Fingers crossed for a permanent solution sometime in the near future.

    Many thanks again.

    The above is close to what we need, but it sounds like by uncommenting that code only *newly created* sites are affected. We would like to network enable Jetpack on a multisite, then automatically connect all *existing* sites to a single wp.com account (in part so as to enforce wp.com authentication on all sites, via method documented here)…how would this be done?

    Sure appreciate,

    Jim P.

    Plugin Author Jeremy Herve

    (@jeherve)

    Jetpack Mechanic ??

    @doctorproctor That’s not possible at the moment, but I’d suggest that you chime in on the GitHub issue with a quick explanation of your setup and your needs. That will help us when we work on designing something to close this issue.

    Thanks!

    Great, sure appreciate your quick reply here (and that of the Jetpack support person as well)…will add my thoughts on GitHub…Jim P.

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Automatically connect a new multisite site to wordpress.com’ is closed to new replies.