Skip to content
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

add a static container for handling local frontend dev #2619

Merged
merged 2 commits into from
Sep 30, 2024
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
10 changes: 10 additions & 0 deletions Dockerfile.static
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
FROM ruby:2.7.8-bullseye AS static

RUN mkdir /code
WORKDIR /code

COPY Gemfile Gemfile.lock /code/

RUN bundle install

COPY . /code
6 changes: 3 additions & 3 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
source "https://rubygems.org"

group :media do
gem "compass", "~>0.12.2"
gem "sass", "~>3.2.5"
gem "susy", "~>1.0.5"
gem "compass", "~>0.12.7"
gem "sass", "~>3.2.19"
gem "susy", "~>1.0.9"
end

group :development do
Expand Down
19 changes: 11 additions & 8 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
GEM
remote: https://rubygems.org/
specs:
chunky_png (1.2.7)
compass (0.12.2)
chunky_png (1.4.0)
compass (0.12.7)
chunky_png (~> 1.2)
fssm (>= 0.2.7)
sass (~> 3.1)
sass (~> 3.2.19)
foreman (0.61.0)
thor (>= 0.13.6)
fssm (0.2.10)
sass (3.2.6)
susy (1.0.5)
sass (3.2.19)
susy (1.0.9)
compass (>= 0.12.2)
sass (>= 3.2.0)
thor (0.17.0)
Expand All @@ -19,7 +19,10 @@ PLATFORMS
ruby

DEPENDENCIES
compass (~> 0.12.2)
compass (~> 0.12.7)
foreman (~> 0.61.0)
sass (~> 3.2.5)
susy (~> 1.0.5)
sass (~> 3.2.19)
susy (~> 1.0.9)

BUNDLED WITH
2.1.4
3 changes: 3 additions & 0 deletions bin/static
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash
cd static
bundle exec sass --compass --scss -I $(dirname $(dirname $(gem which susy))) --trace --watch sass:sass
7 changes: 7 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,13 @@ services:
test: ["CMD", "redis-cli","ping"]
interval: 1s

static:
command: bin/static
build:
dockerfile: Dockerfile.static
volumes:
- .:/code

web:
build: .
image: pythondotorg:docker-compose
Expand Down
362 changes: 170 additions & 192 deletions static/sass/mq.css

Large diffs are not rendered by default.

323 changes: 147 additions & 176 deletions static/sass/no-mq.css

Large diffs are not rendered by default.

677 changes: 328 additions & 349 deletions static/sass/style.css

Large diffs are not rendered by default.