Commit Graph

407 Commits

Author SHA1 Message Date
Leo Puvilland
e05a7b6bb1 flatpak-cache: fix httpd not using the squid proxy correctly...
Signed-off-by: Leo Puvilland <leo@craftcat.dev>
2024-03-06 14:40:56 -08:00
Leo Puvilland
6a37e3b87e flatpak-cache: add ProxyRemote to apache configuration
Signed-off-by: Leo Puvilland <leo@craftcat.dev>
2024-03-04 14:19:44 -08:00
Aurélien Bompard
4accba8e8f Add X-Forwarded-Proto in addition to X-Forwarded-Scheme
The convention is more on `-Proto` than `-Scheme`:
https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-Proto

Signed-off-by: Aurélien Bompard <aurelien@bompard.org>
2024-02-13 12:34:28 +01:00
Francois Andrieu
4479551510 websites: Disable indexing of alt.fp-o/cloud & fix redirect
alt.fpo/en/cloud is still the first link to pop up on search engine and
the current redirect only works with /cloud.
This commit fix the redirect, and prevent this old page to be indexed.
2024-02-06 22:19:14 +01:00
Nick Bebout
d1c563acc2 Revert "Change the httpd proxy stuff to point to ipa02 also"
This reverts commit 65cf67f584.
2024-01-25 11:23:03 -06:00
Nick Bebout
65cf67f584 Change the httpd proxy stuff to point to ipa02 also 2024-01-25 09:06:44 -06:00
Kevin Fenzi
5d24117ce8 proxies / ipa / ui: missing trailing /
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2024-01-24 15:27:01 -08:00
Kevin Fenzi
62279be3e5 proxies / ipa / ui: fix another typo
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2024-01-24 15:21:59 -08:00
Kevin Fenzi
ec09a8d302 proxies / ipa / ui: fix a typo
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2024-01-24 15:20:59 -08:00
Kevin Fenzi
3996374ea0 proxies / ipa / ui: try and edit the referrer for new ipa
New ipa checks the referrer to avoid CSRF issues.
We need to have the proxy edit requests for the right internal hostname
for it to be able to work.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2024-01-24 15:19:14 -08:00
Kevin Fenzi
aeea2c1d06 proxies / koji.fedoraproject.org: disallow robots on koji.fedoraproject.org
Turns out back in 2015 (in 623be6ff73) I added a robots.txt on the koji
hubs to disallow crawling, but since it's behind the proxies, no one
ever saw that robots.txt. Instead they got the default one that just had
a 'crawl-delay 1' in it.

So, lets tell robots to go away for real now, as they are causing load
problems on the koji database and I don't think it's particularly useful
for koji to be indexed. It's a lot of dynamic content anyhow.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2023-11-06 15:48:09 +00:00
Kevin Fenzi
6abea25563 proxies: registry: let ppc64le builders directly access registry
f39 adds flatpaks for ppc64le, so we need to allow ppc64le builders to
access the registry directly so they can install flatpaks in the ostree
install images. Without this they try and get them from the cdn and the
builder firewall blocks them and it times out and the image fails to
compose.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2023-10-31 13:46:57 -07:00
Patrick Creech
ee4df11e44 Remove MultiViews from web configs
Signed-off-by: Patrick Creech <pcreech@redhat.com>
2023-07-20 17:23:40 -04:00
Ryan Lerch
da904d0c41 move legacy css to apps.fp.o/global
This als fixes the broken css on:

* https://fedoraproject.org/easyfix/
* https://torrent.fedoraproject.org
* https://admin.fedoraproject.org/fingerprints

Signed-off-by: Ryan Lerch <rlerch@redhat.com>
2023-04-24 12:09:14 +10:00
Kevin Fenzi
a381bf52e0 proxies / registry: don't use cdn for aarch64 builders either
Right now we only exclude the builders on 10.3.169 from using the
registry cdn (ie, the x86_86 builders), but we also make aarch64
containers/images and we should exclude it too ( 10.3.170.x ).
This might fix a weird compose failure we have been getting on
aarch64 ostree installer images.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2023-04-17 11:46:10 -07:00
Kevin Fenzi
8a4a4469e4 proxies: Override the httpd systemd unit file to up file limit and restart on failure
The proxies seem to be hitting file limits, so try increasing them.
Also, set httpd to restart on failure, this should help mask the problem
if it persists with the higher limit.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2023-01-22 13:51:23 -08:00
Kevin Fenzi
47cf07184e wildcard-2023.fedoraproject.org: new wildcard ssl cert
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2023-01-11 08:48:40 -08:00
Kevin Fenzi
531eee95d3 proxies / reverseproxy: try and fix template to be correct.
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-12-03 20:39:13 -08:00
Kevin Fenzi
3c5ae163f9 proxy: simplify reverseproxy template
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-12-03 20:29:36 -08:00
Kevin Fenzi
b1b0923af0 openshift 3.11: raise a glass!
Our openshift 3.11 cluster(s) served us long and well.

Now we have everything finally moved to the openshift 4 clusters (fas2
was the last holdout). We can finally retire this. :)

🎉🥂

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-11-28 13:08:01 -08:00
Kevin Fenzi
57250588d3 proxies: disable systemd-oomd
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-09-20 12:29:27 -07:00
Kevin Fenzi
91ccdea73f proxies: Reach ocp4 cluster in prod over vpn instead of sending 421
I think I handled all the special cases here already.
We want to switch non iad2 proxies to reach the oco4 cluster over it's
vpn now that it has one. This should allow us to still keep ipv6
available for applications and not have to change dns for moving from
ocp3 cluster anymore. Will roll this out slowly to one proxy then
another, then the rest if it all looks ok.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-13 10:08:48 -07:00
Kevin Fenzi
80ef5e47df proxies / reverseproxypass: try and only 421 ocp4 non iad2 proxies
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-05 13:44:02 -07:00
Kevin Fenzi
42bc4ea41a proxies / reverseproxy: try just always setting balancer_members and dropping the set facts
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-05 11:47:17 -07:00
Kevin Fenzi
7e90378b30 proxies / reverseproxy: Try and clean up logic and whitespace.
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-05 11:24:24 -07:00
Kevin Fenzi
0e1d9f6ea7 proxies / reverseproxy: try some different logic
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-05 09:30:58 -07:00
Kevin Fenzi
dc6b7697c1 proxies / reverseproxy: unset balancer_members after each template so it can get set right for the next one
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-04 21:05:37 -07:00
Kevin Fenzi
e2deffab4e proxies / reverseproxy: consolidate non openshift-iad2 case
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-04 14:51:33 -07:00
Kevin Fenzi
03fe998142 proxies / reverseproxy: also special case the old resultsdbapi
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-04 14:25:32 -07:00
Kevin Fenzi
77bdc05883 proxies / reverseproxy: work around taskotron with its own config
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-04 14:04:07 -07:00
Kevin Fenzi
6d99b43608 proxies / reverspassproxy: fix loop
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-03 20:51:46 -07:00
Kevin Fenzi
6a0727c9e6 proxies / openqa: rework conf file to avoid issue with openqa and its websockets
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-03 20:15:36 -07:00
Kevin Fenzi
7455b3fdb1 proxies / reverseproxy: fix missing )
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-03 14:22:13 -07:00
Kevin Fenzi
52a8936914 proxies: rework reversepassproxy and mark all ocp4 / ocp3 apps
The ocp3 cluster is reachable/available via the vpn, so any proxy can
reach it.

The ocp4 cluster is (at least for now) only reachable/available from the
iad2 proxies (proxy01/proxy10).

There's a firefox bug that causes it to reuse h2 connections, and in
some cases try and request something of a non iad2 proxy that it can't
reach. To work around this in those cases we need to send a 421 back to
the client so it doesn't do that.

This moves that logic into the template so all ocp4: true hosts do this
by default. Also, we default the balancer nodes so we only have to
change them in one place if we remove/add a compute node.

Finally, we mark all the ocp3 apps with 'ocp4: false' so we know what
they are and can move them more easily.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-06-03 13:14:28 -07:00
Kevin Fenzi
0302040f3c proxies / reverseproxy / blockerbugs: have proxies return 421 for non iad2 access.
This is the fun firefox h2 connection reuse bug. blockerbugs is only in
iad2, so if firefox tries to reuse a connection to another proxy for it,
just send it a 421 so it knows thats bad on it.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-05-25 17:29:37 -07:00
Kevin Fenzi
6d1e07d599 proxies / reverseproxy / openqa: do this in a more sustainable way
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-05-11 15:45:14 -07:00
Kevin Fenzi
8d38f818e7 proxies / reverseproxy / openqa: drop unneeded conditional that is causing a syntax error
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-05-11 15:31:26 -07:00
Kevin Fenzi
63adb316a7 proxies / reverseproxy / openqa: make openqa on non iad2 proxies send a 421
Due to http/2 connection reuse bugs, sometimes firefox will decide to
'reuse' a connection to fedoraproject.org for openqa.fedoraproject.org
(since they both have the same tls cert), but openqa is only available
from the 2 iad2 proxies, not all of them. This results in a 503 timeout
and it just not loading. This should make those reused connections get a
421 from proxies and reconnect to the proper ips. (we hope)

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-05-11 13:10:43 -07:00
Francois Andrieu
f9f0942988 docs: disallow indexing of old-docs 2022-04-03 17:54:25 +00:00
Kevin Fenzi
1e712cdc30 Revert "Revert "wildcard-2022.fedoraproject.org cert""
This reverts commit 4430178b29.

It's time to put this back before the cert expires and before we go into
Beta freeze. Hopefully the odd issue with armv7 qemu guests having a
time behind real time is not still happening.
2022-02-21 10:19:17 -08:00
Kevin Fenzi
4430178b29 Revert "wildcard-2022.fedoraproject.org cert"
This reverts commit 57f0d4fdb6.

For an anoying reason, armv7 image builds come up with the time as 10
days ago, which makes this cert invalid. So, move back to the old cert
for a week or so and then switch to the new one again. ;(
2022-01-31 12:39:49 -08:00
Kevin Fenzi
57f0d4fdb6 wildcard-2022.fedoraproject.org cert
This is the renewed version of the old 2020 cert.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2022-01-27 10:37:27 -08:00
Jakub Kadlcik
cc920ed019 httpd: redirect copr /api/ URLs to fedorainfracloud.org
See https://pagure.io/copr/copr/issue/1935

Prevent only /api_2, /api_3, etc from redirectring from
fedoraproject.org to fedorainfracloud.org

I am not entirely sure why do we need these special-cases for API but
you guys are taking care of it and keeping it updated, so it must be
important. If anyone can explain some context, it would be
appreciated. The config is older than my involvement in the Copr
project :-)

Anyway, there is only one /api/ page - https://copr.fedorainfracloud.org/api
and that is not an API endpoint that is programmatically accessed and
that preserves backwards compatibility. It is a page that one opens
in the web browser to find information about API, such as where the
documentation is, and how to obtain an API token.

We would like to apply the redirect from fedoraproject.org to
fedorainfracloud.org even for this page.
2022-01-25 21:43:54 +00:00
Kevin Fenzi
ddfac2e066 proxies: work around reg path issue
reg is putting a /static/ into asset path since it's upgrade.
Just alias it to / here to avoid the problem for now.
Hopefully we are going to be moving to quay.io and can stop caring about
it.

Fixes infra 10673

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2021-12-02 15:42:37 -08:00
Kevin Fenzi
313674646d proxies: increase max workers
Also add a ssl connection cache.
These changes are live on proxy01/10 and seem to have made them stable
again. Will look at pushing to the rest tomorrow.

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2021-09-21 16:19:14 -07:00
Frank Ch. Eigler
d835aba567 debuginfod proxies: preserve & pass %2F etc.
Apache httpd by default blocks URL-encoded / (%2F) characters in the
URL path, even though these are RFC-compliant.  Enable them and permit
their safe passage to the debuginfod servers.

See also https://stackoverflow.com/a/9933890/661150

Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
2021-08-23 11:39:36 +00:00
David Kirwan
55185861c8 metrics-for-apps:
- Updating apache proxy config to handle ocp4 CA cert
- place ocp4 CA cert on proxies
- add ocp4 stg ca cert to haproxy/files

Signed-off-by: David Kirwan <dkirwan@redhat.com>
2021-08-13 20:02:38 +00:00
Frank Ch. Eigler
7185d7774e debuginfod redirect+proxy: combine into handcrafted httpd conf file 2021-05-20 00:42:32 +00:00
Kevin Fenzi
e4a36758f5 debuginfod: add in another slash to make apache happy
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2021-05-11 09:19:26 -07:00
Kevin Fenzi
c66dedd18a debuginfod: add in a slash to make apache happy
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
2021-05-11 09:03:54 -07:00