Skip to content
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
44 changes: 44 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Git
.git
.gitignore

# Docker
Dockerfile
docker-compose.yml
.dockerignore

# Dependencies
node_modules
vendor/
.bundle

# Build outputs
dist/
_site/
.sass-cache/
.jekyll-cache/
.jekyll-metadata

# Logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# OS generated files
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db

# IDE
.vscode/
.idea/
*.swp
*.swo

# Temporary files
*.tmp
*.temp
44 changes: 44 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Use Ruby 3.3.5 as base image
FROM ruby:3.3.5-slim

# Install system dependencies
RUN apt-get update && apt-get install -y \
build-essential \
curl \
git \
&& rm -rf /var/lib/apt/lists/*

# Install Node.js 22.10.0
RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - \
&& apt-get install -y nodejs

# Verify versions
RUN ruby --version && node --version && npm --version

# Set working directory
WORKDIR /app

# Copy dependency files first for better caching
COPY Gemfile Gemfile.lock ./
COPY package.json package-lock.json* ./

# Install bundler and Ruby gems
RUN gem install bundler
RUN bundle config set --local path 'vendor/bundle'
RUN bundle install

# Install Node.js packages
RUN npm install

# Copy the rest of the application
COPY . .

# Set up Jekyll source directory
ENV JEKYLL_ENV=development
ENV BUNDLE_PATH=vendor/bundle

# Expose port 4000 for Jekyll
EXPOSE 4000

# Default command - can be overridden in docker-compose
CMD ["npm", "run", "watch"]
97 changes: 16 additions & 81 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3,43 +3,20 @@ GEM
specs:
addressable (2.8.7)
public_suffix (>= 2.0.2, < 7.0)
bigdecimal (3.1.8)
colorator (1.1.0)
concurrent-ruby (1.3.4)
em-websocket (0.5.3)
eventmachine (>= 0.12.9)
http_parser.rb (~> 0)
eventmachine (1.2.7)
ffi (1.17.0)
ffi (1.17.0-aarch64-linux-gnu)
ffi (1.17.0-aarch64-linux-musl)
ffi (1.17.0-arm-linux-gnu)
ffi (1.17.0-arm-linux-musl)
ffi (1.17.0-arm64-darwin)
ffi (1.17.0-x86-linux-gnu)
ffi (1.17.0-x86-linux-musl)
ffi (1.17.0-x86_64-darwin)
ffi (1.17.0-x86_64-linux-gnu)
ffi (1.17.0-x86_64-linux-musl)
ffi (1.17.2)
forwardable-extended (2.6.0)
google-protobuf (4.28.3)
bigdecimal
rake (>= 13)
google-protobuf (4.28.3-aarch64-linux)
bigdecimal
rake (>= 13)
google-protobuf (4.28.3-arm64-darwin)
bigdecimal
rake (>= 13)
google-protobuf (4.28.3-x86-linux)
bigdecimal
rake (>= 13)
google-protobuf (4.28.3-x86_64-darwin)
bigdecimal
rake (>= 13)
google-protobuf (4.28.3-x86_64-linux)
bigdecimal
rake (>= 13)
google-protobuf (3.25.8)
google-protobuf (3.25.8-aarch64-linux)
google-protobuf (3.25.8-arm64-darwin)
google-protobuf (3.25.8-x86-linux)
google-protobuf (3.25.8-x86_64-darwin)
google-protobuf (3.25.8-x86_64-linux)
http_parser.rb (0.8.0)
i18n (1.14.6)
concurrent-ruby (~> 1.0)
Expand Down Expand Up @@ -82,82 +59,40 @@ GEM
rexml (3.3.9)
rouge (4.5.1)
safe_yaml (1.0.5)
sass-embedded (1.80.6)
google-protobuf (~> 4.28)
rake (>= 13)
sass-embedded (1.80.6-aarch64-linux-android)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-aarch64-linux-gnu)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-aarch64-linux-musl)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-aarch64-mingw-ucrt)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-arm-linux-androideabi)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-arm-linux-gnueabihf)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-arm-linux-musleabihf)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-arm64-darwin)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-riscv64-linux-android)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-riscv64-linux-gnu)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-riscv64-linux-musl)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-x86-cygwin)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-x86-linux-android)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-x86-linux-gnu)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-x86-linux-musl)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-x86-mingw-ucrt)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-x86_64-cygwin)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-x86_64-darwin)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-x86_64-linux-android)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-x86_64-linux-gnu)
google-protobuf (~> 4.28)
sass-embedded (1.80.6-x86_64-linux-musl)
google-protobuf (~> 4.28)
sass-embedded (1.69.5)
google-protobuf (~> 3.23)
rake (>= 13.0.0)
terminal-table (3.0.2)
unicode-display_width (>= 1.1.1, < 3)
unicode-display_width (2.6.0)
webrick (1.9.0)

PLATFORMS
aarch64-linux
aarch64-linux
aarch64-linux-android
aarch64-linux-gnu
aarch64-linux-musl
aarch64-mingw-ucrt
arm-linux
arm-linux
arm-linux-androideabi
arm-linux-gnu
arm-linux-gnueabihf
arm-linux-musl
arm-linux-musleabihf
arm64-darwin
riscv64-linux
riscv64-linux-android
riscv64-linux-gnu
riscv64-linux-musl
ruby
x86-cygwin
x86-linux
x86-linux
x86-linux-android
x86-linux-gnu
x86-linux-musl
x86-mingw-ucrt
x86_64-cygwin
x86_64-darwin
x86_64-linux
x86_64-linux-android
x86_64-linux-gnu
x86_64-linux-musl

DEPENDENCIES
Expand Down
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,23 @@ The site was recently overhauled. Here you can find documentation on how to add

## Running Locally

### Using Docker

A [`Dockerfile`](./Dockerfile) and [`docker-compose.yml`](./docker-compose.yml) are provided to build and view the website locally using a containerised environment. To build the docker container use

```sh
docker compose build
```

And then run the container with:

```sh
docker compose up
```

The site is viewable at [`http://localhost:4000/`](http://localhost:4000/).


### Tools

- (`asdf` for runtime version management)
Expand Down
10 changes: 5 additions & 5 deletions content/_includes/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,18 @@
{% endif %}

<!--{\%- seo -\%}-->
<link rel="icon" href="{{ constants.favicon | absolute_url }}" />
<link rel="stylesheet" href="{{ 'properties.css' | absolute_url }}" />
<link rel="stylesheet" href="{{ 'main.css' | absolute_url }}" />
<link rel="icon" href="{{ constants.favicon | relative_url }}" />
<link rel="stylesheet" href="{{ 'properties.css' | relative_url }}" />
<link rel="stylesheet" href="{{ 'main.css' | relative_url }}" />
{% include external/mathjax.html -%}
{% include external/font.html %}
<script type="text/javascript" src="{{ "site.js" | absolute_url }}" charset="utf-8"></script>
<script type="text/javascript" src="{{ "site.js" | relative_url }}" charset="utf-8"></script>
{% if page.react and (site.pages | where: "name" page.name) %}
{%- assign react_source = page.name | append: ".js" -%}
{% elsif (site.collections | where: "label" page.collection) %}
{%- assign react_source = page.layout | append: ".js" %}
{% else %}
{%- assign react_source = "default.js" -%}
{% endif %}
<script type="text/javascript" src="{{ react_source | absolute_url }}" charset="utf-8"></script>
<script type="text/javascript" src="{{ react_source | relative_url }}" charset="utf-8"></script>
</head>
2 changes: 1 addition & 1 deletion content/_includes/post-list.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
{%- assign date_format = constants.date_format | default: "%b %-d, %Y" -%}
<span class="text-sm">{{ post.date | date: date_format }}</span>
<div class="text-lg">
<a class="block font-medium" href="{{ post.url | absolute_url }}">
<a class="block font-medium" href="{{ post.url | relative_url }}">
{{ post.title | escape }}
</a>
</div>
Expand Down
2 changes: 1 addition & 1 deletion content/pages/search.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ title: Search Results
react: true
---

<script type="text/javascript" src="{{ "store.js" | absolute_url }}" charset="utf-8"></script>
<script type="text/javascript" src="{{ "store.js" | relative_url }}" charset="utf-8"></script>
{%- include react/root.html id='site-search' -%}
2 changes: 1 addition & 1 deletion content/properties.css.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ permalink: properties.css

@layer components {
:root {
--fiqci-banner-image: url({{ '/assets/images/FiQCI-banner.jpg' | absolute_url }});
--fiqci-banner-image: url({{ '/assets/images/FiQCI-banner.jpg' | relative_url }});
}
}
4 changes: 2 additions & 2 deletions content/site.js.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ permalink: site.js
"key": "{{ forloop.index }}",
"type": "{{ publication.filters.Type | default: 'Post' }}",
"title": "{{ publication.title }}",
"url": "{{ publication.url | absolute_url }}",
"url": "{{ publication.url | relative_url }}",
"date": "{{ publication.date | date: '%-d.%-m.%Y' }}",
"teaser": "{{ publication.header.teaser | absolute_url }}",
"teaser": "{{ publication.header.teaser | relative_url }}",
"filters": {
{%- for category in publication.filters %}
"{{ category[0] }}": "{{ category[1] }}"
Expand Down
18 changes: 18 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
services:
fiqci-dev:
build: .
ports:
- "4000:4000"
- "35729:35729"
volumes:
# Mount source code but exclude dependencies
- .:/app
- /app/node_modules # prevent host's node_modules from overriding container's node_modules
- /app/vendor # prevent host's vendor directory from overriding container's Ruby gems
environment:
- BUNDLE_PATH=vendor/bundle
- NODE_ENV=development
- JEKYLL_ENV=development
- JEKYLL_HOST=0.0.0.0
command: npm run watch
working_dir: /app
Loading