add netlify config
This commit is contained in:
parent
9909da14b0
commit
37e84d8cd5
5 changed files with 39 additions and 25 deletions
|
@ -33,26 +33,38 @@ steps:
|
|||
when:
|
||||
event: [ pull_request, push ]
|
||||
|
||||
publish:
|
||||
image: bitnami/git
|
||||
# Must be set in Woodpecker configuration
|
||||
secrets:
|
||||
- codeberg_token
|
||||
environment:
|
||||
DEST_REPONAME: dest_repo
|
||||
commands:
|
||||
# Git configuration
|
||||
- git config --global user.email noreply@example.com
|
||||
- git config --global user.name "Woodpecker CI"
|
||||
- git clone https://$CODEBERG_TOKEN@codeberg.org/lila-network/pages.git $DEST_REPONAME
|
||||
# Copy build step output to repository folder
|
||||
- cp -ar ./hugo_public/. $DEST_REPONAME/
|
||||
# Needed for custom domains
|
||||
- cp .domains $DEST_REPONAME || true # Ignore if it doesn't exist
|
||||
# Commit and push all static files with pipeline started timestamp
|
||||
- cd $DEST_REPONAME
|
||||
- git add .
|
||||
- git commit -m "Woodpecker CI ${CI_BUILD_CREATED}"
|
||||
- git push
|
||||
|
||||
netlify-deploy:
|
||||
image: node:alpine
|
||||
when:
|
||||
event: push
|
||||
secrets:
|
||||
- NETLIFY_AUTH_TOKEN
|
||||
- NETLIFY_SITE_ID
|
||||
commands:
|
||||
- npm install netlify-cli -g
|
||||
- netlify deploy --prod --dir ./hugo_public
|
||||
|
||||
# publish:
|
||||
# image: bitnami/git
|
||||
# # Must be set in Woodpecker configuration
|
||||
# secrets:
|
||||
# - codeberg_token
|
||||
# environment:
|
||||
# DEST_REPONAME: dest_repo
|
||||
# commands:
|
||||
# # Git configuration
|
||||
# - git config --global user.email noreply@example.com
|
||||
# - git config --global user.name "Woodpecker CI"
|
||||
# - git clone https://$CODEBERG_TOKEN@codeberg.org/lila-network/pages.git $DEST_REPONAME
|
||||
# # Copy build step output to repository folder
|
||||
# - cp -ar ./hugo_public/. $DEST_REPONAME/
|
||||
# # Needed for custom domains
|
||||
# - cp .domains $DEST_REPONAME || true # Ignore if it doesn't exist
|
||||
# # Commit and push all static files with pipeline started timestamp
|
||||
# - cd $DEST_REPONAME
|
||||
# - git add .
|
||||
# - git commit -m "Woodpecker CI ${CI_BUILD_CREATED}"
|
||||
# - git push
|
||||
# when:
|
||||
# event: push
|
||||
|
|
|
@ -1,4 +0,0 @@
|
|||
lila.network
|
||||
lila-network.codeberg.page
|
||||
pages.lila-network.codeberg.page
|
||||
pages.pages.lila-network.codeberg.page
|
0
static/.well-known/matrix/.gitkeep
Normal file
0
static/.well-known/matrix/.gitkeep
Normal file
1
static/.well-known/matrix/test
Normal file
1
static/.well-known/matrix/test
Normal file
|
@ -0,0 +1 @@
|
|||
{"m.server": "matrix.example.com:443"}
|
5
static/netlify.toml
Normal file
5
static/netlify.toml
Normal file
|
@ -0,0 +1,5 @@
|
|||
[[headers]]
|
||||
for = "/.well-known/matrix/*"
|
||||
[headers.values]
|
||||
Content-Type = "application/json"
|
||||
Access-Control-Allow-Origin = "*"
|
Loading…
Reference in a new issue