Reverse Proxy for blog.imagifyr.com on Siteground.
Does anyone run a reverse-proxy to their blog? I am hosting imagifyr.com on railway and blog.imagifyr.com on siteground. I'm not too familiar with networking, but requests pass through railway and the IP address keeps getting blocked by Siteground's bots.
Does anyone know how to resolve this? @Brody
P.S. I followed this guide: https://myrailslearnings.wordpress.com/2020/01/18/how-do-i-add-a-wordpress-blog-to-my-rails-app/
P.S. I followed this guide: https://myrailslearnings.wordpress.com/2020/01/18/how-do-i-add-a-wordpress-blog-to-my-rails-app/
admin
My Ruby on Rails Learnings
How Do I Add a WordPress Blog to My Rails App?
I wanted to have a robust blog for my Rails app, but I didnβt want to spend too much time on it. Initially I created a simple model (Articles) and added TinyMCE in it, but I ran into some chaβ¦
48 Replies
Project ID:
N/A
why was I summoned lol
Lol, darn I'm sorry if I woke you up or something, not urgent. Just siteground redirecting me when I'm running a reverse proxy to my blog.
I was awake, just curious as to why I was picked to be pinged haha
Honestly, because you are a π . Not because you are the only person I know who is supporting railway on his shoulders. π
π
LMK if there's someone else I should have pinged instead lol.
LMK if there's someone else I should have pinged instead lol.
I assume the blog is wordpress right?
Yes sir. WP on siteground.
so the obvious solution is to run wordpress on Railway π
I tried doing that but failed multiple times. You can have imagifyr.com on one container and blog.imagifyr.com on another and reverse proxy into each other?
why do you need a reverse proxy? they are different domains
Because imagifyr.com is a rails app hosted on railway and i just wanted imagifyr.com/blog to point to blog.imagifyr.com for SEO purposes which is why I did it that way.
by point do you mean redirect?
Yes sir, my poor choice of wording. π
and that's an in-code redirect?
can you send clickable links to both domains, I'm on mobile
Yeah, my route is
On my rails app.
https://imagifyr.com
https://imagifyr.com/blog (the redirect)
https://blog.imagifyr.com (blog hosted on siteground)
do you need access to the filesystem of your wordpress install on siteground?
I have access, but do I need to get in there? No.
so let's just move your wordpress install to Railway?
you could keep the same blog. subdomain
Hm. Ok, I will try again. What you're saying is just create a new project "imagifyr-wordpress" for example and that will have the blog. subdomain and I will reverse proxy into that instead?
You would want to have all services that relate to the other services in the same project, from that screenshot it looks like you are taking backups of your database over the public network and subjecting yourself to egress fees, instead of using the private network, you would want the backup service in the same project so that it can connect to the database via the private network.
you would also want the wordpress site in the same project as well.
and I'm still not seeing any need for a reverse proxy? can you please explain where you think it fits in?
RE: Backup, yeah it's on AWS right now and I'm not doing such volume that it will cost me much (right now it's nothing).
RE: So I would put the WP site in imagifyr from what it sounds like?
RE: Reverse proxy. Networking noob here. But I'm imagining, if I have another service (Wordpress with blog.imagifyr.com). It would be accessed via blog.imagifyr.com.
But I want that blog accessible at imagifyr.com/blog instead. That's where I think the reverse proxy is necessary?
so you aren't happy with just the redirect?
Sorry, not on the same page I think. I'm fine with the redirect. imagifyr.com/blog just needs to be able to reach the wordpress blog.
If your suggested setup accomplishes that, I'm good.
yeah then you don't need a reverse proxy, you just attach the blog subdomain to the wordpress service
why does the imagifyr service have a wildcard?
It was just setup that way. Should I not have the wildcard?
if you don't need a wildcard, there's no reason to have one
Gotcha, I will give this a shot over the weekend. Thanks for the lessons sir!
yeah just deploy the wordpress template Jack made, don't worry about the domain yet, just use the railway provided domain to get it all setup, then use some kind of wordpress backup and restore plugin to backup the wordpress install on your old host and restore it to the wordpress install on railway
See. G.O.A.T i tell you! G.O.A.T!
Thanks for your help this morning sir! Hope you have a happy 4th!
haha I'm not American, but thank you π
@Jack anyway to increase the max upload filesize to more than 50mb? https://help.servmask.com/2018/10/27/how-to-increase-maximum-upload-file-size-in-wordpress/
I am importing my WP from siteground to here but the file size is about 150mb...
Yani I
ServMask Helpdesk
How to Increase Maximum Upload File Size in WordPress - ServMask He...
There are 4 ways that you can choose to increase the maximum upload file size in WordPress. 1. Use our plugin (easy) https://import.wp-migration.com 2. Contact hosting provider (medium) Reach over to the customer support of your hosting provider and ask them to increase these limits for you If you are still unable to import your [β¦]
Would be nice if I can go access the .htaccess or something and just edit it.
how large is your backup file?
About 150MB.
try setting the
WORDPRESS_CONFIG_EXTRA
variable to -
OK trying. Would
@ini_set('upload_max_filesize','128M')
be something like @ini_set('upload_max_filesize','170M')
if my import file is 157MB though?oh, sorry didnt notice the edit
edited
Np. Deploying now! Thanks for the help!
Sorry to keep bugging you, but the
WORDPRESS_CONFIG_EXTRA
didn't seem to update the upload limit or do I have to wait for post deploy to finish because it's been stuck like that for some time.are you sure that isnt a limitation of the plugin?
Pretty certain. I made another edit to bring up Plugin Editor:
https://www.ionos.com/digitalguide/hosting/blogs/activate-wordpress-theme-and-plug-in-editor/
With
define('DISALLOW_FILE_EDIT', false)
And it isn't being applied. I'm using All in one WP Migration and according to this blog: https://wpadventure.com/how-to-increase-the-all-in-one-wp-migration-plugin-upload-import-limit/
The default seems to be 512MB.
My hunch is that the deploying isn't taking notice of the WORDPRESS_CONFIG_EXTRA
IONOS Digital Guide
How to enable Theme- and Plugin Editor in WordPress
When you set up your WordPress installation with our Click & Buildapplications, we make some settings and add features to make creating your website easier and safer. For example, we disable the theme and plugin editors. This article explains how you can reactivate the Theme and Plugin Editor afterwards.
WP Adventure
How to increase the size (import) limit in All in One WP Migration ...
You can now easily increase the size (import) limit for the All in One WP Migration plugin. This post with screenshots is an easy guide.
okay ill deploy wordpress and see what i can figure out
Sorry for the trouble and thanks for your help!
no problem!
https://servmask.com/products/unlimited-extension
Remove upload limitsyou might have better luck with backing up the database on your current host and restoring it to the database on railway, and then copying over your /var/www/html folder on your current host into the volume on the mysql service
Might just copy and paste the posts, I'm not sure how to do that. There's only 9 posts so far.
whatever works best for you
Thanks for your help today anyways!
no problem