-
Notifications
You must be signed in to change notification settings - Fork 1
49 lines (37 loc) · 1.07 KB
/
docker-image.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Docker Image CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
deploy:
# why can't this by nginx, like my docker images?
runs-on: ubuntu-22.04
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup docker buildx
uses: docker/setup-buildx-action@v1
- name: Build AlexGames docker image (get build dependencies)
run: |
docker build -t alexgames_build_wasm \
-f docker/http_server/Dockerfile.build_wasm \
.
- name: Build AlexGames static HTML via docker
run: |
docker run --rm \
-v $(pwd):/app \
alexgames_build_wasm
- name: Copy AlexGames static HTML to hosting path
run: |
mkdir -p public && \
cp -r build/wasm/out/http_out/* ./public
- name: Deploy built HTML to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./public
destination_dir: docs