Skip to content

Commit

Permalink
Added font to docker image for consistent PNG rendering
Browse files Browse the repository at this point in the history
  • Loading branch information
beveradb committed Mar 7, 2024
1 parent 981932b commit b3c8c2e
Show file tree
Hide file tree
Showing 10 changed files with 162 additions and 163 deletions.
5 changes: 2 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,8 @@ FROM python:3.12-slim
RUN apt-get update && apt-get install -y graphviz wget && rm -rf /var/lib/apt/lists/*

# Install fonts
RUN mkdir /usr/share/fonts/truetype/Avenir-Next && \
wget -qO- https://raw.githubusercontent.com/prchann/fonts/main/Avenir%20Next/400%20Regular/avenir-next-regular.ttf > /usr/share/fonts/truetype/Avenir-Next/Avenir-Next.ttf && \
fc-cache -fv
COPY fonts /usr/share/fonts/truetype/custom
RUN fc-cache -fv

# Set the working directory
WORKDIR /app
Expand Down
6 changes: 3 additions & 3 deletions examples/full.example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@ ecosystem:
style:
diagramEngine: neato
diagramOverlap: prism
diagramOverlapScaling: 4.5
diagramOverlapScaling: 4
diagramOverlapShrink: true
diagramPadding: 0.5
diagramRankdir: LR
groupLabelShape: box
groupLabelStyle: rounded
groupLabelFontname: Avenir Next, Helvetica
groupLabelFontcolor: "#333333"
groupLabelFontsize: 25
groupLabelMargin: 0.3
groupLabelFontsize: 18
groupLabelMargin: 0.22
defaultLogoScale: 1.5
centralTool:
label: Kubernetes
Expand Down
Binary file modified examples/full.example_logos.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
130 changes: 65 additions & 65 deletions examples/full.example_logos.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
174 changes: 87 additions & 87 deletions examples/full.example_text.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified examples/minimal.example_logos.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/minimal.example_logos.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/minimal.example_text.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added fonts/Avenir Next.ttc
Binary file not shown.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"

[tool.poetry]
name = "logo-diagram-generator"
version = "0.2.1"
version = "0.2.2"
description = "Generate SVG diagrams of a (tech) ecosystem, using logos from each tool organised into groups around a central logo"
authors = ["Andrew Beveridge <[email protected]>"]
license = "MIT"
Expand Down

0 comments on commit b3c8c2e

Please sign in to comment.