Skip to content

Commit

Permalink
build docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Felix Mayer authored and Felix Mayer committed Feb 5, 2024
1 parent 25f4656 commit e517ccc
Show file tree
Hide file tree
Showing 4 changed files with 89 additions and 192 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/build-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Build ResMon Docs

on:
push:
branches: []

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Log in to Docker Hub
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Cache Docker layers
uses: actions/cache@v3
with:
path: /tmp/.buildx-cache
key: ${{ runner.os }}-buildx-${{ github.sha }}
restore-keys: |
${{ runner.os }}-buildx-
- name: Build and push Docker image
uses: docker/build-push-action@v3
with:
context: .
file: ./docker/Documentation.Dockerfile
push: true
tags: yertools/res-mon-docs:latest
labels: yertools/res-mon-docs
builder: ${{ steps.buildx.outputs.name }}
platforms: linux/amd64,linux/arm/v7,linux/arm64/v8
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache
10 changes: 10 additions & 0 deletions docker/Documentation.Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
FROM node:18

WORKDIR /usr/src/app

COPY . .

RUN npm install --production

EXPOSE 8322
CMD ["npx", "elm-doc-preview", "--no-browser", "--port", "8322"]
Loading

0 comments on commit e517ccc

Please sign in to comment.