Is there a way (preferably via configuration) to change the default url context path root of airflow webserver
i:e instead of deployment the server like
localhost:8080/admin/...
I would like the root path be like
localhost:8080/mywebserver/admin/...
I would like to avoid a reverse proxy in front of the airflow just to rewrite the root path.
I checked the [webserver] section in airflow.cfg and able to find the base_url configuration that helping to change the default URL context path.
Update the airflow.cfg and restart the webserver.
[webserver]
base_url = http://localhost:8080/mywebserver
Airflow web ui with updated base_url
Related
I have deployed an aws sample app and I have created url redirects within my default /etc/nginx/nginx.conf and my redirects work.
My problem is: when placing in my nginx.conf file within .platform/nginx/nginx.conf, the file does not overwrite the default nginx.conf file.
I have attempted to write scripts in eb extension to move my custom nginx.conf file but this does not work.
FYI: AMI linux 2 ,php version 8.0 +
What do you suggest ?
I have a dash application in a compute engine instance that I'm looking to view in my browser. HTTP and HTTPS traffic is enabled and the instance has a static IP address. The apache server works and when I first ran an application, the default index page located at /var/www/html showed up at the browser address http://EXTENAL_IP_OF_VM_INSTANCE
From what I've seen elsewhere, web application files tend to be stored in the /var/www directory and the index.html file is present as the default page. However I have a single app.py file that I want to run which is located in the /home/user directory, so not in any particular web directory.
I run the app by entering python3 app.py and it does run:
Running on http://127.0.0.1:8050/ (Press CTRL+C to quit)
However, going to the instance's external IP address (34.89.0.xx) in my browser doesn't show the app, instead it shows text from an old 'hello world' application I made previously, that I thought I had deleted but is still showing up.
Part of the server configuration file apache2.conf is below:
The sites-available folder contains two files, 000-default.conf and default-ssl.conf, both with /var/www/html as the DocumentRoot. 000-default.conf is also in the sites-available folder, and is the only file there.
I tried changing the DocumentRoot in these files to /home/user where the app.py file is which didn't work, then I tried moving the file to the web directory /var/www which didn't work either.
Does anyone have any suggestions on how to fix this so that I can see my application in the browser?
I would like to change the URL for my Wordpress:
From this: www.example.com/wordpress
To this: www.example.com/game
What do I need to do?
I tried renaming the Wordpress folder to game but this did not work. It caused a linkage problem with the bank-end database.
which server you are using.
if you are using apache or nginx you need to modify you vhost files accordingly to point to the right directory.
location of these file depend on you server's OS.
commonly it is in /etc/httpd/conf.d/ or /etc/apache2/conf.d/
Not open any file in this www.example.com/wordpress folder, Change permission this folder apply 755 permission, stop apache server or stop xampp. after rename your foder name and start apache server or xammp
I'm using Vagrant in order to produce a reusable development server and I'm using Puppet to provision it with a configuration generated with PuPHPet. It's a basic LEMP stack.
Everything is working fine however the nginx user is running as www-data and the synced folders are owned by the vagrant user. Because of this nginx can't write data to the /var/www directory which is causing my Laravel application to throw an exception.
I can manually change the ownership using chown however I'd like to just run nginx as the vagrant user and have that change in my configuration file.
What changes to the Puppet configuration do I need to make to make that happen?
PuPHPet is using the puppetlabs-nginx module which has an nginx::params class in it which in it's turn defines certain nginx config variables including $nx_daemon_user. That said it looks like in your PuPHPet generated manifest you'd want to replace
include nginx::params
with
class {'nginx::params':
nx_daemon_user => 'vagrant',
}
I am using a grails application as backend for a Flex frontend. To be able to easily develop and debug my applications I would need to place a crossdomain.xml file into the root of the server, i.e. it must be accessible via http://localhost:8080/crossdomain.xml. Similar use cases might be the deployment of a favicon.ico or a robots.txt, however this can be done in the production environment through a tomcat server with a default root web application.
In my case however I need to have the crossdomain.xml available after running grails run-app. I know that I can move the entire application to the root (http://ca.rroll.net/2009/03/27/configuring-the-grails-root-application-context/) however this is also not what I want, since the grails application should still reside below its default application context.
Does somebody know, how I can do this? Will I have to reconfigure the jetty servlet container of my grails installation somehow?
I think I found the answer. I haven't tried this yet, so YMMV.
In this article, Colin Harrington discusses making a crossdomain.xml file available at the root of the server by deploying an additional Jetty context.
His technique was first proposed in this blog entry, where the author also discusses using the Static Resources Plugin as another alternative
I figured out a way to solve this with Apache and mod_proxy. This allows both your Grails install and Grails project to remain pristine. No hacking at the Grails internals, no adding plug-ins you may not need in production.
1. Install Apache httpd 2.2
Do this however makes the most sense for your operating system. It is important that you install Apache 2.2. I did this on an Ubuntu system, so any specific commands and file locations will be for Ubuntu. Modify as necessary for your system.
After you've installed Apache, start httpd.
sudo /sbin/service httpd start
Test that it is installed correctly using a web browser.
2. Create a root directory
Pick a location on your disk where you will keep your static files. This will be the document root for httpd. I will be using /var/grails_root.
mkdir /var/grails_root
touch /var/grails_root/crossdomain.xml
3. Create a VirtualHost in httpd.conf
Open httpd.conf in your favorite text editor.
vim /etc/httpd/conf/httpd.conf
Pick your favorite port, and create a virtual host on that port. I will be using 9090, but any port will do.
Add these lines to httpd.conf
Listen 9090
<VirtualHost *:9090>
DocumentRoot "/var/grails_root"
<Directory "/var/grails_root">
Allow from all
</Directory>
</VirtualHost>
Restart httpd
sudo /sbin/service httpd restart
Test that you are now able to access the static files in your document root directory. If not, you will need to fix this before moving on to the next step.
4. Enable mod_proxy and mod_proxy_http
You need to load both of these modules. mod_proxy has the base functionality for proxying, and the mod_proxy_xxx modules have information specific to a protocol. They ship standard with httpd 2.2, so you shouldn't need to install anything extra.
Add these lines to httpd.conf
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_http_module modules/mod_proxy_http.so
Now modify the virtual host you set up in the previous step. (You can omit the comments)
<VirtualHost *:9090>
DocumentRoot "/var/grails_root"
<Directory "/var/grails_root">
Allow from all
</Directory>
# New lines start here
ProxyRequests Off
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
ProxyPass /grailsApp http://your.grails.server:8080/grailsApp
# New lines end here
</VirtualHost>
Restart httpd
sudo /sbin/service httpd restart
Now, you should be able to access both your static files and your Grails app via port 9090.
This is all based on information found here: http://docs.codehaus.org/display/JETTY/Configuring+mod_proxy
Information for doing this with other versions of Apache is available on the same site.