Add Sentry, use env var for site

This commit is contained in:
SkyfallWasTaken 2024-07-14 14:14:14 +01:00
parent 1321d866c4
commit 1bf9af4349
4 changed files with 18 additions and 3 deletions

6
.env.example Normal file
View file

@ -0,0 +1,6 @@
GITHUB_TOKEN=
SITE=https://skyfall.dev
SENTRY_DSN=https://dcb9a70c83e31d8a586a268507af35c4@o4506847832440832.ingest.us.sentry.io/4507600335863808
SENTRY_PROJECT_SLUG=skyfalldev
SENTRY_AUTH_TOKEN=

View file

@ -2,14 +2,21 @@ import { defineConfig } from "astro/config";
import mdx from "@astrojs/mdx";
import sitemap from "@astrojs/sitemap";
import tailwind from "@astrojs/tailwind";
import sentry from '@sentry/astro';
import "dotenv/config"
import svelte from "@astrojs/svelte";
// https://astro.build/config
export default defineConfig({
// FIXME: don't hardcode this
site: "https://skyfall.dev",
integrations: [mdx(), sitemap(), tailwind(), svelte()],
site: process.env.SITE,
integrations: [mdx(), sitemap(), tailwind(), svelte(), sentry({
dsn: process.env.SENTRY_DSN,
sourceMapsUploadOptions: {
project: process.env.SENTRY_PROJECT_SLUG,
authToken: process.env.SENTRY_AUTH_TOKEN
}
})],
/* output: "hybrid", // or 'server'
experimental: {
actions: true,

BIN
bun.lockb

Binary file not shown.

View file

@ -13,6 +13,7 @@
"dependencies": {
"@astrojs/svelte": "^5.6.0",
"@fontsource-variable/plus-jakarta-sans": "^5.0.21",
"@sentry/astro": "^8.17.0",
"activity-calendar-widget": "^0.0.14",
"octokit": "^4.0.2",
"svelte": "^4.2.18",
@ -28,6 +29,7 @@
"@tailwindcss/aspect-ratio": "^0.4.2",
"@tailwindcss/typography": "^0.5.13",
"astro": "^4.11.5",
"dotenv": "^16.4.5",
"prettier": "^3.3.2",
"prettier-plugin-astro": "^0.14.0",
"tailwindcss": "^3.4.4",