-
Notifications
You must be signed in to change notification settings - Fork 637
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Docs: π Move docs generator to Starlight and typedoc (#2717)
* Docs: π Move docs generator to Starlight and typedoc * Docs: π Add deployable implementation via fly.io * Docs: π· Fix configuration on typedoc generation * Docs: π Add additional pro and docker docs * Docs: β Add one compose file * Docs: β Remove jsdoc and update links to new url
- Loading branch information
1 parent
acd60b5
commit f147533
Showing
42 changed files
with
1,850 additions
and
1,156 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
name: Docs CD Deploy | ||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- 'docs-src/**' | ||
|
||
jobs: | ||
deploy: | ||
name: Deploy Docs | ||
runs-on: ubuntu-latest | ||
concurrency: deploy-group # optional: ensure only one action runs at a time | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: superfly/flyctl-actions/setup-flyctl@master | ||
- run: | | ||
flyctl deploy --config docs-src/fly.toml --dockerfile docs-src/Dockerfile | ||
env: | ||
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
services: | ||
redwood: | ||
build: | ||
context: . | ||
volumes: | ||
- .:/app | ||
- yarn_cache:/root/.yarn/berry/cache | ||
- node_cache:/root/.cache | ||
ports: | ||
- "8910:8910" | ||
depends_on: | ||
- db | ||
environment: | ||
DATABASE_URL: postgresql://redwood:redwood@db:5432/redwood | ||
DIRECT_URL: postgresql://redwood:redwood@db:5432/redwood | ||
TEST_DATABASE_URL: postgresql://redwood:redwood@db:5432/redwood_test | ||
SESSION_SECRET: super_secret_session_key_change_me_in_production_please | ||
POSTHOG_API_KEY: "POSTHOG_API_KEY" | ||
SHEPHERD_PUBLIC_KEY: "SHEPHERD_PUBLIC_KEY" | ||
NODE_ENV: production | ||
|
||
db: | ||
image: postgres:16-bookworm | ||
environment: | ||
POSTGRES_USER: redwood | ||
POSTGRES_PASSWORD: redwood | ||
POSTGRES_DB: redwood | ||
ports: | ||
- "5432:5432" | ||
volumes: | ||
- postgres:/var/lib/postgresql/data | ||
|
||
volumes: | ||
yarn_cache: | ||
node_cache: | ||
postgres: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# build output | ||
dist/ | ||
# generated types | ||
.astro/ | ||
|
||
# dependencies | ||
node_modules/ | ||
|
||
# logs | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
|
||
|
||
# environment variables | ||
.env | ||
.env.production | ||
|
||
# macOS-specific files | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# build output | ||
dist/ | ||
# generated types | ||
.astro/ | ||
|
||
# dependencies | ||
node_modules/ | ||
|
||
# generated api docs | ||
src/content/docs/api/* | ||
|
||
# logs | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
|
||
|
||
# environment variables | ||
.env | ||
.env.production | ||
|
||
# macOS-specific files | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"recommendations": ["astro-build.astro-vscode"], | ||
"unwantedRecommendations": [] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"command": "./node_modules/.bin/astro dev", | ||
"name": "Development server", | ||
"request": "launch", | ||
"type": "node-terminal" | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# syntax = docker/dockerfile:1 | ||
|
||
# Adjust NODE_VERSION as desired | ||
ARG NODE_VERSION=20.10.0 | ||
FROM node:${NODE_VERSION}-slim as base | ||
|
||
LABEL fly_launch_runtime="Astro" | ||
|
||
# Astro app lives here | ||
WORKDIR /app | ||
|
||
# Set production environment | ||
ENV NODE_ENV="production" | ||
|
||
# Install pnpm | ||
ARG PNPM_VERSION=8.15.6 | ||
RUN npm install -g pnpm@$PNPM_VERSION | ||
|
||
|
||
# Throw-away build stage to reduce size of final image | ||
FROM base as build | ||
|
||
# Install packages needed to build node modules | ||
RUN apt-get update -qq && \ | ||
apt-get install --no-install-recommends -y build-essential node-gyp pkg-config python-is-python3 | ||
|
||
# Install node modules | ||
COPY --link package.json pnpm-lock.yaml pnpm-workspace.yaml ./ | ||
|
||
# Copy library code | ||
COPY --link ./shepherd.js ./shepherd.js | ||
|
||
# Copy application code | ||
COPY --link ./docs-src ./docs-src | ||
RUN pnpm install --frozen-lockfile --prod=false | ||
|
||
# Build application | ||
RUN pnpm -F shepherd-docs run build | ||
|
||
# Remove development dependencies | ||
RUN pnpm prune --prod | ||
|
||
|
||
# Final stage for app image | ||
FROM nginx | ||
|
||
# Copy built application | ||
COPY --from=build /app/docs-src/dist /usr/share/nginx/html | ||
|
||
# Start the server by default, this can be overwritten at runtime | ||
EXPOSE 80 | ||
CMD [ "/usr/sbin/nginx", "-g", "daemon off;" ] |
Oops, something went wrong.