changed dockerfile to arm64

This commit is contained in:
Erik Grobecker 2024-10-18 08:50:32 +02:00
parent 5e4e21009b
commit 6ee25b9230
Signed by: Erik
GPG key ID: 80D020D0ABBD3FB2
4 changed files with 16 additions and 3 deletions

10
Dockerfile Normal file
View file

@ -0,0 +1,10 @@
FROM --platform=arm64 alpine:3.20.3 AS zola
RUN apk add zola
COPY . /project
WORKDIR /project
RUN ["zola", "build"]
FROM --platform=arm64 ghcr.io/static-web-server/static-web-server:2
WORKDIR /
COPY --from=zola /project/public /public

View file

@ -3,7 +3,6 @@ title = "test"
draft = false
insert_anchor_links = "left"
tags = [ "typst" ]
render = true
# [extra]
# poor = true

View file

@ -1,5 +1,5 @@
# use PowerShell instead of sh:
#set shell := ["powershell.exe", "-c"]
set shell := ["powershell.exe", "-c"]
# view the blog as it would be published in a browser
@ -9,3 +9,6 @@ view:
# view the blog with drafts in a browser
view-drafts:
zola serve --drafts -f
build-con:
docker build --platform linux/amd64,linux/arm64 -t git.grobecker.me/erik/blog:latest --push .

View file

@ -1,7 +1,8 @@
providers = ["...", "staticfile"]
[phases.setup]
nixPkgs = ["zola"]
nixPkgs = ["cargo-binstall", "cargo"]
cmds = ["cargo binstall https://github.com/getzola/zola.git"]
[phases.build]
cmds = ["zola build"]