Modulus.io and Meteor - Deploy to a subdomain - meteor

I have an app in development that I've deployed to Galaxy and it works great! There are two versions of the site, each in different languages. I am using a standard domain for the English version http://website.com and a subdomain for the French version http://fr.website.com
When using the standard $ meteor deploy, you can specify the domain you're sending it to. For example, I can keep a French branch and an English branch in the same repository, and then deploy to $ meteor deploy fr.website.com when I want to deploy to the French subdomain.
I've properly configured the DNS settings with Godaddy.
The syntax appears to be different with Modulus.io... How do I deploy a different version of the site to a subdomain using Modulus.io?

You need to add your domain in "CUSTOM DOMAINS" at the Project Administration and you also need to set the ROOT_URL environment variable.

Related

How can I deploy a Next.js project to my main domain and install WordPress in a subdomain using Nginx on an AWS EC2 instance

I have a domain name, "mydomain.com", and I want to deploy a Next.js project to the main domain and install WordPress in a subdomain, "wp.mydomain.com". I need to accomplish this on an AWS EC2 instance using **Nginx **as the web server.
For the Next.js project, I have already built the project using npm run build. However, I'm not sure how to configure Nginx to serve the project from the root domain.
For WordPress, I need to know how to install and configure it in a subdomain using Nginx. Specifically, I need to know how to install PHP and MySQL, configure Nginx to serve the **subdomain **from the WordPress directory, and set up SSL using Let's Encrypt.
Can anyone provide detailed step-by-step instructions or point me to relevant documentation or tutorials for deploying Next.js and WordPress with Nginx on an AWS EC2 instance? Any help or guidance would be greatly appreciated!
I have already built the Next.js project using npm run build, and I have installed Nginx on my AWS EC2 instance. I have also set up the DNS records to point the domain and subdomain to my EC2 instance. However, when I try to access the root domain or the subdomain, I see an error message or a default Nginx page, instead of the expected content from the Next.js project or WordPress site.
I was expecting to see the content from my Next.js project when I visit the root domain, and the WordPress site when I visit the subdomain. I also want to make sure that the website is served securely over HTTPS using Let's Encrypt.

Ho to configure WordPress with GitLab

I'm pretty new to this, but I want to configure my GitLab repo to my Cpanel hosting account. So when I push changes from my local site (environment using local by flywheel) to GitLab it automatically goes to the staging site and if everything is good to the production site.
I have managed to connect my Cpanel account with GitLab by using Deploy HQ. However, I'm trying to understand the best way to set all of this up. Currently, I'm only tracking my themes folder in GitLab. My issue is that when I deploy, all that is getting uploaded is the themes folder(obviously). How do I set this up so it will upload the full WordPress site and database? Also, how do I set it up with staging and production, would I have two different branches connected to two different directories on cpanel?
I'm just looking for some noob friendly advice on how to set up this infrastructure for WordPress Git and Cpanel.

How to fix a cloned AMI with another domain SSL certificate on it for Wordpress on AWS?

In 2018 I made a Wordpress site by using a Bitnami AMI for a AWS EC2. Fine developed a site and created another custom AMI of the finalized Wordpress site. This was for domain X.
Now in 2020 I wanted to duplicate that website by using this custom AMI for domain Y. I have created an EC2 based on that custom AMI and instance went online without problems.
The problem is now that I can not reach the site by its url, I got blocked by "This connection is invalid", I also see that certificate is still based on the domain of 2018, thus is invalid. So I think that the issue is caused by the SSL configuration based on domain X while it is iinitiated for domain Y. But since I am not able to reach the site neither the admin panel, I am wondering how I can disable the SSL/HTTPS enforcement so that I can reach the site and admin panel?
I do have access to SSH, so probably I should be able to do something from there? But totally not known with that type OS and usage via SSH.
Bitnami Engineer here,
As you created a snapshot of the 2018 instance, the new instance has the same configuration you had at that time. Please check the following items so you can update the certificates and the app's configuration to work properly using your new domain name:
The certificates are configured in the /opt/bitnami/apache2/conf folder by default. You probably substituted the ones we include with valid certificate files for your domain in 2018. You will need to substitute the server.crt and server.key now with the new ones.
https://docs.bitnami.com/aws/apps/wordpress/administration/enable-https-ssl-apache/
Regarding the WordPress configuration, we have configuration tool that takes care of updating the domain name in the database. Can you take a look at this guide?
https://docs.bitnami.com/aws/faq/configuration/configure-custom-domain/
You will basically need to run sudo /opt/bitnami/apps/wordpress/bnconfig --machine_hostname my-new-domain.com.
I also suggest you check the WordPress' configuration file (/opt/bitnami/apps/wordpress/htdocs/wp-config.php) to see if you edited the WP_HOME and WP_SITE parameters there.

Developing on plesk

Trying to figure the best way to develop on plesk.
I would like to develop my wordpress website on a temporary url, and attach the production domain only when I am done developing.
From some reason I'm getting various dns errors, saw a guide referring to change of hosts file but it dosent seem like the perfect solution to me.
Any tips?
You may create the clone of your WP instance (staging) and use Plesk Git extension for developing this staging WP site. After making all necessary changes on staging non-public clone you can publish it to a production domain to make it publicly available.

Map domain to a subdirectory of another domain

Our main site (www.example.com) is hosted internally on IIS/ASP.NET servers but we've recently created a blog, which is hosted externally on a Linux/Apache configuration (www.exampleblog.com).
At the moment, we've managed to map the blog to a subdomain of our main site (blog.example.com), but we would prefer it to be mapped to a subdirectory (www.example.com/blog) instead.
Is this possible and, if so, how can it be done?
Well this depends, but let me consider your blog is been developed on PHP.
Mainly you need to do the following :
Install PHP on you Windows box.
Configure and active PHP in IIS.
Create a folder in you website maybe you call it blog.
From the IIS turn this folder to an App.
Well and that's it.
Note: Am not sure what platform you are running in your blog but basically the main idea is to configure the windows box to run the other site and if it is php you would find many examples about that.
If you have another web server (Apache) behind the blog site, the only way is a redirect from www.example.com/blog to the other web server. You can also use a frame containing the blog site (which is located under another address) so the user doesn't see the other address in the address bar of his/her browser.

Resources