🔧 Use cloudfront distribution

This commit is contained in:
Luke Vella 2024-09-09 21:24:57 +01:00
parent 4bd35c2c8b
commit 47049eeefa
No known key found for this signature in database
GPG key ID: 469CAD687F0D784C
2 changed files with 2 additions and 2 deletions

View file

@ -23,7 +23,7 @@ const nextConfig = {
pathname: "/api/storage/**", pathname: "/api/storage/**",
}, },
{ {
hostname: "rallly-public.s3.amazonaws.com", hostname: "d39ixtfgglw55o.cloudfront.net",
}, },
], ],
}, },

View file

@ -25,7 +25,7 @@ export function OptimizedAvatarImage({
<AvatarImage src={src} alt={name} /> <AvatarImage src={src} alt={name} />
) : isAvatarsEnabled ? ( ) : isAvatarsEnabled ? (
<Image <Image
src={`/api/storage/${src}`} src={`https://d39ixtfgglw55o.cloudfront.net/${src}`}
width={128} width={128}
height={128} height={128}
alt={name} alt={name}