@@ -44,41 +44,41 @@ We provide you with a template to accomplish this task easily.
44
44
Create a file called ` .gitlab-ci.yml ` in the root directory of your
45
45
repository and copy the contents of the template below.
46
46
47
- Note:
48
-
49
- Each version of Alpine Linux supports a single version of Zola, for example:
50
-
51
- Alpine Linux 3.20 supports Zola version 0.18.0.
52
- Alpine Linux 3.21 supports Zola version 0.19.2.
53
-
54
- Make sure the version of Zola you specify in ` ZOLA_VERSION ` is supported by your version of the Alpine image.
47
+ Make sure you specify a version of Zola in the ` ZOLA_VERSION ` variable.
55
48
56
49
``` yaml
57
50
stages :
58
51
- deploy
59
52
60
53
default :
61
- image : alpine:3.21
54
+ image : debian:stable-slim
62
55
63
56
variables :
64
57
# The runner will be able to pull your Zola theme when the strategy is
65
58
# set to "recursive".
66
59
GIT_SUBMODULE_STRATEGY : " recursive"
67
60
68
- # Make sure you specify a supported version of Zola whenever
69
- # you upgrade the version of the Alpine image.
70
- # Use semantic versioning (semver) format (x.y.z).
71
- # See https://pkgs.alpinelinux.org/packages
61
+ # Make sure you specify a version of Zola here.
62
+ # Use the semver format (x.y.z) to specify a version.
63
+ # For example: "0.17.2" or "0.18.0".
72
64
ZOLA_VERSION :
73
65
description : " The version of Zola used to build the site."
74
- value : " 0.19.2 "
66
+ value : " "
75
67
76
68
pages :
77
69
stage : deploy
78
70
script :
79
71
- |
80
- apk add zola=~${ZOLA_VERSION}
81
- zola build --base-url $CI_PAGES_URL
72
+ apt-get update
73
+ DEBIAN_FRONTEND=noninteractive apt-get install --assume-yes --no-install-recommends wget ca-certificates
74
+ zola_url="https://github.com/getzola/zola/releases/download/v$ZOLA_VERSION/zola-v$ZOLA_VERSION-x86_64-unknown-linux-gnu.tar.gz"
75
+ if ! wget --quiet --spider $zola_url; then
76
+ echo "A Zola release with the specified version could not be found.";
77
+ exit 1;
78
+ fi
79
+ wget $zola_url
80
+ tar -xzf *.tar.gz
81
+ ./zola build --base-url $CI_PAGES_URL
82
82
83
83
artifacts :
84
84
paths :
0 commit comments