forked from nuxt/movies
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Deployment configuration base-nuxt for filmz.
- Loading branch information
1 parent
89b160a
commit 484cf7e
Showing
2 changed files
with
103 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: 'Deployment' | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
- master | ||
- develop | ||
|
||
jobs: | ||
build_and_deploy: | ||
name: Build and Deploy | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: 'Checkout' | ||
uses: actions/checkout@v3 | ||
with: | ||
ref: ${{ github.event.workflow_run.head_branch }} | ||
fetch-depth: 0 | ||
|
||
- name: 'Pakman' | ||
uses: upmaru/pakman@alpine-3.18-7.4 | ||
with: | ||
command: 'bootstrap' | ||
env: | ||
ABUILD_PRIVATE_KEY: ${{secrets.ABUILD_PRIVATE_KEY}} | ||
ABUILD_PUBLIC_KEY: ${{secrets.ABUILD_PUBLIC_KEY}} | ||
|
||
- name: 'Build APK' | ||
uses: upmaru/pakman@alpine-3.18-7.4 | ||
with: | ||
entrypoint: /var/lib/pakman/bin/build.sh | ||
|
||
- name: 'Archive' | ||
uses: upmaru/pakman@alpine-3.18-7.4 | ||
with: | ||
entrypoint: /var/lib/pakman/bin/archive.sh | ||
|
||
- name: 'Create Deployment' | ||
uses: upmaru/pakman@alpine-3.18-7.4 | ||
with: | ||
command: 'create_deployment' | ||
archive: 'packages.zip' | ||
env: | ||
WORKFLOW_REF: ${{ github.ref }} | ||
WORKFLOW_SHA: ${{ github.sha }} | ||
INSTELLAR_ENDPOINT: https://sandbox.opsmaru.dev | ||
INSTELLAR_PACKAGE_TOKEN: ${{secrets.INSTELLAR_PACKAGE_TOKEN}} | ||
INSTELLAR_AUTH_TOKEN: ${{secrets.INSTELLAR_AUTH_TOKEN}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
dependencies: | ||
build: | ||
- nodejs-current | ||
- npm | ||
- vips-dev | ||
runtime: | ||
- nodejs-current | ||
- npm | ||
- bash | ||
- curl | ||
- s6 | ||
- jq | ||
- ca-certificates | ||
- icu-data-full | ||
- filmz-openrc | ||
trace: true | ||
|
||
stack: alpine/3.18 | ||
|
||
build: | ||
command: | | ||
npm install | ||
npm run build | ||
destinations: | ||
- .output | ||
|
||
run: | ||
name: filmz | ||
services: | ||
- binary: node | ||
name: web | ||
path: /usr/bin | ||
start: | ||
call: .output/server/index.mjs | ||
|
||
hook: | ||
post-deinstall: | | ||
rc-service filmz stop | ||
rc-update del filmz | ||
post-install: | | ||
rc-update add filmz | ||
post-upgrade: | | ||
rc-service filmz start | ||
pre-upgrade: | | ||
rc-service filmz stop | ||
kits: | ||
- description: Web service configuration | ||
main: true | ||
name: web | ||
ports: | ||
- main: true | ||
name: web | ||
target: 3000 |