parent
120d4f2a9e
commit
21a9dd27e6
5 changed files with 35 additions and 5 deletions
|
@ -6,9 +6,7 @@ jobs:
|
|||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: hello world action step
|
||||
uses: ./actions/hello
|
||||
with:
|
||||
who-to-greet: 'lubi'
|
||||
- name: Get the output time
|
||||
run: echo "The time was ${{ steps.hello.outputs.time }}"
|
||||
uses: ./actions/hugo-two
|
||||
- name: show files
|
||||
run: ls -lR
|
||||
|
||||
|
|
12
actions/hugo-two/Dockerfile
Normal file
12
actions/hugo-two/Dockerfile
Normal file
|
@ -0,0 +1,12 @@
|
|||
FROM alpine:latest
|
||||
|
||||
RUN apk add --no-cache \
|
||||
brotli \
|
||||
gzip \
|
||||
hugo
|
||||
|
||||
ADD entrypoint.sh /entrypoint.sh
|
||||
RUN chmod +x /entrypoint.sh
|
||||
|
||||
ENTRYPOINT ["/entrypoint.sh"]
|
||||
|
7
actions/hugo-two/README.md
Normal file
7
actions/hugo-two/README.md
Normal file
|
@ -0,0 +1,7 @@
|
|||
# Forgejo-Action for building hugo pages
|
||||
|
||||
This Action builds a hugo site and runs both gzip and brotli on static text files so a properly configured webbrowser can serve those precompressed files
|
||||
|
||||
The compression only works on files in the "public" folder of the actions workdir.
|
||||
|
||||
|
5
actions/hugo-two/action.yml
Normal file
5
actions/hugo-two/action.yml
Normal file
|
@ -0,0 +1,5 @@
|
|||
name: 'hugo'
|
||||
despriction: 'oguh'
|
||||
runs:
|
||||
using: 'docker'
|
||||
image: 'Dockerfile'
|
8
actions/hugo-two/entrypoint.sh
Executable file
8
actions/hugo-two/entrypoint.sh
Executable file
|
@ -0,0 +1,8 @@
|
|||
#!/bin/sh
|
||||
|
||||
#hugo
|
||||
#find ./public -type f -regex ".*\.\(css\|html\|js\|json\|svg\|xml\)$" \
|
||||
# -exec brotli --best -f {} \+ \
|
||||
# -exec gzip --best -k -f {} \+
|
||||
sleep 3
|
||||
exit 0
|
Loading…
Reference in a new issue