feat: try buildah
This commit is contained in:
parent
5fab71837a
commit
1cfc0a44e6
2 changed files with 33 additions and 26 deletions
|
@ -22,32 +22,34 @@ jobs:
|
||||||
name: 🚢 Deploy
|
name: 🚢 Deploy
|
||||||
runs-on: docker
|
runs-on: docker
|
||||||
container:
|
container:
|
||||||
image: node:lts
|
image: quay.io/buildah/stable:latest
|
||||||
if: github.ref == 'refs/heads/main'
|
if: github.ref == 'refs/heads/main'
|
||||||
needs: [check]
|
needs: [check]
|
||||||
steps:
|
steps:
|
||||||
- uses: https://github.com/actions/checkout@v4
|
- run: buildah build -f Containerfile .
|
||||||
|
|
||||||
- uses: https://github.com/denoland/setup-deno@v2
|
# - uses: https://github.com/actions/checkout@v4
|
||||||
with:
|
#
|
||||||
deno-version: v2.x
|
# - uses: https://github.com/denoland/setup-deno@v2
|
||||||
- run: deno task install
|
# with:
|
||||||
- run: deno task build
|
# deno-version: v2.x
|
||||||
|
# - run: deno task install
|
||||||
- name: build containerfile
|
# - run: deno task build
|
||||||
id: build-image
|
#
|
||||||
uses: https://github.com/redhat-actions/buildah-build@v2
|
# - name: build containerfile
|
||||||
with:
|
# id: build-image
|
||||||
image: website
|
# uses: https://github.com/redhat-actions/buildah-build@v2
|
||||||
tags: latest
|
# with:
|
||||||
containerfiles: |
|
# image: website
|
||||||
./Containerfile
|
# tags: latest
|
||||||
|
# containerfiles: |
|
||||||
- name: Push to registry
|
# ./Containerfile
|
||||||
uses: https://github.com/redhat-actions/push-to-registry@v2
|
#
|
||||||
with:
|
# - name: Push to registry
|
||||||
image: ${{ steps.build-image.outputs.image }}
|
# uses: https://github.com/redhat-actions/push-to-registry@v2
|
||||||
tags: ${{ steps.build-image.outputs.tags }}
|
# with:
|
||||||
username: token
|
# image: ${{ steps.build-image.outputs.image }}
|
||||||
password: ${{ secrets.GITHUB_TOKEN }}
|
# tags: ${{ steps.build-image.outputs.tags }}
|
||||||
registry: ${{ github.server_url }}/${{ github.repository }}
|
# username: token
|
||||||
|
# password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
# registry: ${{ github.server_url }}/${{ github.repository }}
|
||||||
|
|
|
@ -1,6 +1,11 @@
|
||||||
|
FROM docker.io/denoland/deno AS build
|
||||||
|
COPY . .
|
||||||
|
RUN deno task install
|
||||||
|
RUN deno task build
|
||||||
|
|
||||||
FROM ghcr.io/swablab/documents:latest AS documents
|
FROM ghcr.io/swablab/documents:latest AS documents
|
||||||
|
|
||||||
FROM docker.io/nginxinc/nginx-unprivileged:latest
|
FROM docker.io/nginxinc/nginx-unprivileged:latest
|
||||||
COPY ./nginx.conf /etc/nginx/conf.d/default.conf
|
COPY ./nginx.conf /etc/nginx/conf.d/default.conf
|
||||||
COPY ./dist /usr/share/nginx/html
|
COPY --from=build ./dist /usr/share/nginx/html
|
||||||
COPY --from=documents / /usr/share/nginx/html/docs
|
COPY --from=documents / /usr/share/nginx/html/docs
|
Loading…
Add table
Reference in a new issue