Compare commits
3 Commits
simplify-t
...
master
Author | SHA1 | Date | |
---|---|---|---|
![]() |
e91dee5059 | ||
![]() |
0d62eb876a | ||
![]() |
af1c2f8bb2 |
45
.gitea/workflows/build.yml
Normal file
45
.gitea/workflows/build.yml
Normal file
@ -0,0 +1,45 @@
|
||||
name: Deploy
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Build
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v4
|
||||
- name: Install dependencies
|
||||
run: echo y | npm exec -- pnpm install
|
||||
- name: Build project
|
||||
run: npm exec -- pnpm build
|
||||
- name: Upload production-ready build files
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: dist
|
||||
path: ./dist
|
||||
|
||||
deploy:
|
||||
name: Deploy
|
||||
needs: build
|
||||
runs-on: host
|
||||
|
||||
steps:
|
||||
- name: Download artifact
|
||||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
name: dist
|
||||
path: ./dist
|
||||
|
||||
# Deploy to local repo
|
||||
- name: Move files to server
|
||||
run: |
|
||||
rm -rf /var/www/martials.no/*
|
||||
cp -r dist/* /var/www/martials.no
|
59
.github/workflows/build.yml
vendored
59
.github/workflows/build.yml
vendored
@ -1,59 +0,0 @@
|
||||
name: Deploy
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Build
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- uses: pnpm/action-setup@v2
|
||||
with:
|
||||
version: 8
|
||||
|
||||
- name: Setup Node
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: 18
|
||||
|
||||
- name: Install dependencies
|
||||
run: pnpm install
|
||||
|
||||
- name: Build project
|
||||
run: pnpm build
|
||||
|
||||
- name: Upload production-ready build files
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: production-files
|
||||
path: ./dist
|
||||
|
||||
deploy:
|
||||
name: Deploy
|
||||
needs: build
|
||||
runs-on: ubuntu-latest
|
||||
if: github.ref == 'refs/heads/master'
|
||||
|
||||
steps:
|
||||
- name: Download artifact
|
||||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
name: production-files
|
||||
path: ./dist
|
||||
|
||||
# Deploy to local repo
|
||||
- name: Deploy
|
||||
uses: s0/git-publish-subdir-action@develop
|
||||
env:
|
||||
REPO: self
|
||||
BRANCH: build
|
||||
FOLDER: dist
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
@ -5,7 +5,7 @@ import { Link } from "./link"
|
||||
const Footer: Component<SimpleProps> = ({ className }) => (
|
||||
<footer class={`container absolute bottom-0 py-5 text-center ${className}`}>
|
||||
<p>
|
||||
Kildekode på <Link to={"https://github.com/h600878/martials.no"}>GitHub</Link>
|
||||
Kildekode på <Link to={"https://git.martials.no/martials/old.martials.no"}>Gitea</Link>
|
||||
</p>
|
||||
</footer>
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user