Skip to content

get the site out #23

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
May 31, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -172,3 +172,6 @@ cython_debug/

# Misc
.DS_Store

# Node packages
node_modules
10 changes: 9 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@ COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/
ENV PYTHONDONTWRITEBYTECODE=1
ENV PYTHONUNBUFFERED=1

# Add nodejs v22
RUN apt-get update \
&& apt-get install -y curl gnupg \
&& curl -fsSL https://deb.nodesource.com/setup_22.x | bash - \
&& apt-get install -y nodejs \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

WORKDIR /app

# Copy the project into the image
Expand All @@ -16,4 +24,4 @@ RUN find /app -name "*.sqlite3" -delete
# Sync the project into a new environment, using the frozen lockfile
RUN uv sync --frozen

ENTRYPOINT [ "/app/entrypoint.sh" ]
ENTRYPOINT [ "/app/entrypoint.sh" ]
1 change: 1 addition & 0 deletions deploy_prod.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ mkdir -p ${LOG_DIR}

# update changes before update
# git pull
npm install
source .venv/bin/activate
uv sync
cd pythonkr_backend
Expand Down
1 change: 1 addition & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@


cd /app
npm install
source .venv/bin/activate
uv sync
cd /app/pythonkr_backend
Expand Down
102 changes: 102 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"devDependencies": {
"cross-env": "^7.0.3"
}
}
Comment on lines +1 to +5
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Populate standard metadata and scripts
A minimal package.json should include name, version, and optionally scripts, license, and other fields to support npm workflows and clarify the package’s intent.

Example diff:

 {
+  "name": "pythonkr-frontend",
+  "version": "0.1.0",
   "devDependencies": {
     "cross-env": "^7.0.3"
   },
+  "scripts": {
+    "build:css": "cross-env NODE_ENV=production tailwindcss build"
+  },
+  "license": "MIT"
 }
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
{
"devDependencies": {
"cross-env": "^7.0.3"
}
}
{
"name": "pythonkr-frontend",
"version": "0.1.0",
"devDependencies": {
"cross-env": "^7.0.3"
},
"scripts": {
"build:css": "cross-env NODE_ENV=production tailwindcss build"
},
"license": "MIT"
}
🤖 Prompt for AI Agents
In package.json lines 1 to 5, the file lacks standard metadata fields such as
"name" and "version" which are essential for npm package identification and
management. Add at least the "name" and "version" fields at the top level of the
JSON object. Optionally, include a "scripts" section for common commands and a
"license" field to clarify usage rights. Ensure the JSON structure remains valid
and properly formatted.

38 changes: 6 additions & 32 deletions pythonkr_backend/fixtures.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,40 +17,14 @@
}
},
{
"model": "wagtailcore.page",
"model": "wagtailcore.site",
"pk": 1,
"fields": {
"path": "0001",
"depth": 1,
"numchild": 1,
"translation_key": "0bddbb0f-7275-4646-81a5-c89de32daa6c",
"locale": 1,
"latest_revision": null,
"live": true,
"has_unpublished_changes": false,
"first_published_at": null,
"last_published_at": null,
"live_revision": null,
"go_live_at": null,
"expire_at": null,
"expired": false,
"locked": false,
"locked_at": null,
"locked_by": null,
"title": "Root",
"draft_title": "Root",
"slug": "root",
"content_type": [
"wagtailcore",
"page"
],
"url_path": "/",
"owner": null,
"seo_title": "",
"show_in_menus": false,
"search_description": "",
"latest_revision_created_at": null,
"alias_of": null
"hostname": "localhost",
"port": 80,
"site_name": "",
"root_page": 3,
"is_default_site": true
}
},
{
Expand Down
12 changes: 2 additions & 10 deletions pythonkr_backend/theme/static_src/tailwind.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,15 +51,7 @@ module.exports = {
* comment the line below to disable '@tailwindcss/forms'.
*/
require('@tailwindcss/forms'),
plugins: [
/**
* '@tailwindcss/forms' is the forms plugin that provides a minimal styling
* for forms. If you don't like it or have own styling for forms,
* comment the line below to disable '@tailwindcss/forms'.
*/
require('@tailwindcss/forms'),
require('@tailwindcss/typography'),
require('@tailwindcss/aspect-ratio'),
],
require('@tailwindcss/typography'),
require('@tailwindcss/aspect-ratio'),
],
}