Static WordPress Community

Static HTML Output plugin not crawling Local Flywheel site

Yep, that wizard/UI is work in progress, but you can just start your Docker containers via Docker itself to get them back up after restart

Depending on your OS, if Windows, you get some kind of Docker GUI thing

On Mac, something like this

Screen Shot 2020-08-18 at 5.24.48 am

Awesome! That did the trick.

For Windows users, just click on the Docker icon in the system tray, select Docker Dashboard, locate your Wordpress site’s container, hover the container to reveal options, and click the run / play icon.

Looks like this:
image

Any other Windows users finding this thread should also check out this YouTube video for install instructions: https://www.youtube.com/watch?v=0kRors_YhDM

I’m impressed. Already works better than Local for me. Hope you continue to develop this. Not that it needs much work as far as I can tell - maybe just some more documentation.

1 Like

Sweet!!!

Thanks so much for sticking with this and trying it out.

I’m quite excited to bring in the ideas to improve it from head to code.

You’ll see things like the convenient management functions, such as quick backup snapshots (using Docker’s snapshots behind the scenes). There’s an open issue I’ve got in GitHub to add a nice web based code editor, which may be enough for most people to work on sites and streamlining the static conversion and deployment, but for time being will still do via WP2Static web UI as on any server

1 Like

Thank you for the free software and amazing support.

Look forward to seeing Lokl mature.

1 Like

Follow up question regarding backups with Lokl…

Lokl installs WPBackItUp plugin. WPBackItUp restore instructions say you have to log into your WP host’s phpMyAdmin or mySQL admin tool to restore the database.

Is this possible with Lokl? If so, where do I find phpMyAdmin, mySQL admin, or the equivalent Lokl tool?

Thanks again!

Ah, right. Only CLI based mysql admin in that current Lokl you’re using.

To get into that via CLI, if you have the container’s ID, something like:

docker exec -it CONTAINERID /bin/sh

will get you in, then can use general msyql command line commands, but that may not be very fun.

If WPBackitUp doesn’t have a free import, then that was probably a bad choice by me - not very happy with any of the freely available backup plugins, most try to upsell for convenient functions.

Are you trying to import an existing site into Lokl? I’m a bit out of touch on which ones would be best there, but I think @gulshan may have an idea?

For just backup/restores, I was planning to add easy to use interface on top of these docker commands:

But haven’t tested yet. So, we may need to try a few things in this thread

Doesn’t sound fun and a little outside my comfort zone.

I haven’t found a free one I like either :frowning:

No, not trying to import now. Just trying to plan and test how I’ll use Lokl. Whenever I edit the site my plan is to (1) back it up and then (2) create the static .zip to push to GitHub/Netlify.

Hopefully I don’t ever need to use the backups but it’s nice to know I can restore a backup if needed.

That would be an awesome feature!

Do you know of any non-local / cloud-based host services designed only for exporting static sites? Kinda like a traditional wordpress host the host would only serves the site to the logged in admin. As a windows users I’d love that so I don’t have to worry about my local environment. And it seems there’d be benefits for non-windows users too (e.g. cloud backups, accessible when away from local machine, etc).

I’m working on exactly this, using WP2Static v7 and deploying to S3/CloudFront. If you have (or create) a GitHub account, you can log in at https://app.staticweb.io and give it a try. It’s not officially launched yet, and I could use the testing and feedback. The “management” section is extremely basic, but the actual WP server setup is rock solid. E.g., everything on the server is backed up every 24 hours, but there’s no UI to restore the backups yet. But you can just hit me up if you need support, and improvements that I make for StaticWeb get committed to WP2Static.

There are some existing static WP hosts like Strattic and HardyPress. They use proprietary plugins. I haven’t used them myself.

1 Like

Thanks for letting me know about Strattic and HardyPress. Checked them out. Seem a little bloated - I don’t need them to host my static site (I’d prefer AWS or Netlify) - and I believe static hosting should be cheaper but they seem more expensive than many traditional WP hosts.

I checked out https://app.staticweb.io too. I was surprised at how fast the site was ready. Seemed like it was instant. Whether it’s Local, Lokl, traditional WP host, etc. it always seemed like it’d take a minute to build a new site. That was cool.

After clicking “view live site” and verifying install, I clicked “manage” and was taken the the Dashboard. From there I edited the Sample Page title and then tried to do static stuff and got lost.

I clicked on WP2Static, clicked “generate static site” and after a few minutes the green “WP2Static: Deployed” notification appeared.

It took me a while to figure out what that did. I was able to figure it out but it wasn’t intuitive. Expected as you’ve been focused on technical stuff not UI.

I noticed the logs said “S3 Addon deploying” so I went looking for that. Found the Addons choice from the WP2Static dropdown. Found the bucked name and with a little trial and error was able to insert it into this formula - http://[bucketname].s3.amazonaws.com/index.html - to get to my site.

But it also looks like CF distribution was created and I’m missing the benefits of CF if I go straight to S3. IDK my site’s CF URL.

That was my experience. I’ve got multiple sites and I got them all set up on Lokl yesterday so I’m going with that for the time being but will be interested to see how this progresses.

Here are my three main observations:

  • Make the site’s AWS URL easy to find. The green “WP2Static: Deployed” button should be clickable and take users to the AWS site.
  • How do I set up a custom domain?
  • IDK how I feel about you hosting my site on your AWS account. For cost and control reasons, I think I might prefer to have that on my own AWS account.

Update: Some of the URLs on the S3 site link back to the staticweb.io site. In the screenshot below, I’m on the S3 site but the circled link takes me back to the staticweb.io site.

image

2 Likes

Cool, sounds like staticweb has a nice workflow (I haven’t tried it out myself yet).
Feel free to do the back and forth about it in this forum as long as needed @john-shaffer or pull into your preferred channel.

@tjc4 I can only speak to the WP2Static side of things, so can guess at the rewriting issue you’ve encountered and should be back to dealing with those kind of issues in that repo soon.

Leon, IDK if this is the same issue or not but I noticed that static sites I generate with Lokl + Simpler Static (default settings on both) include failed requests to the localhost (see screenshot).

Seems kinda similar to the mix of S3 production and local host development links I found in John’s staticweb.io site so maybe there’s some connection.

Could also be because I added the reSmush.it Image Optimizer plugin (the bundled Autoptimize plugin see to do anything for images though I didn’t spend much time playing with it) and it seems that it’s mostly (one exception) images that are affected.

I’ll play around (disabling reSmush.it, trying Simpler Static’s absolute URLs option) and report back when I get a chance but let me know if you have any ideas in the interim. Thanks again!

image

If you can reproduce, can you please log an issue with the dev site’s good code block and the same code block from the static site in the GitHub repo?

My guess is either the above (rewritten HTML has an issue) OR that it’s failed to discover, crawl and save the path in question (you can confirm this by inspecting the exported site’s contents).

There are only a few rewriting/detection issues in Static HTML Output left at current, since doing a big bug fix marathon with @gulshan’s help a few months ago. So, it’s possibly one of those issues still open in GitHub

Oh, and just to be sure, you’re using the Static HTML Output 6.6.21 in all of those Lokl containers, not the one that’s installed by default, which is quite old, before a lot of fixes still

Cool, sounds like staticweb has a nice workflow (I haven’t tried it out myself yet).
Feel free to do the back and forth about it in this forum as long as needed @john-shaffer or pull into your preferred channel.

I’ve moved it to DM just to not clutter up the other conversation.

Switching from Simpler Static to Static HTML Output resolved the issue and everything is working now. Just make that change to the Lokl plugins and I think it’s ready to go.

1 Like

Cool. Sorry for the delay. Just replied.

Great to hear! I got a little done on Lokl last week, but not enough for a new release. Hopefully after next dev session!

Update: It’s still good so far going. Glad to have this solution, Fast solution for Windows users. :clap:

1 Like

Great, thanks for confirming! Will merge it in eventually :smiley: