51 lines (49 loc) · 1.82 KB
/
deploy-now.yaml
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
50
51
name: Deploy Now
on:
- push
- workflow_dispatch
jobs:
deploy-now:
runs-on: ubuntu-latest
steps:
- name: Fetch project data
uses: ionos-deploy-now/retrieve-project-info-action@v1
id: project
with:
api-key: ${{ secrets.IONOS_API_KEY }}
project: ${{ secrets.IONOS_PROJECT_ID }}
service-host: api-us.ionos.space
- name: checkout
if: ${{ steps.project.outputs.deployment-enabled == 'true' }}
uses: actions/checkout@v2
with:
submodules: 'recursive'
- name: Setup Node.js 14.x
if: ${{ steps.project.outputs.deployment-enabled == 'true' }}
uses: actions/setup-node@v1
with:
node-version: 14.x
- name: Prepare project environment
if: ${{ steps.project.outputs.deployment-enabled == 'true' }}
run: |
npm install --global yarn
yarn install --frozen-lockfile
- name: Build project
if: ${{ steps.project.outputs.deployment-enabled == 'true' }}
run: yarn build
env:git config --global user.name "BrokenXOStiletto"
git config --global user brokenstiletto15@gmail.com
CI: true
SITE_URL: ${{ steps.project.outputs.site-url }}
- name: Deploy build
if: ${{ steps.project.outputs.deployment-enabled == 'true' }}
uses: ionos-deploy-now/deploy-to-ionos-action@v1
with:
api-key: ${{ secrets.IONOS_API_KEY }}
bootstrap-deploy: ${{ steps.project.outputs.bootstrap-deploy }}
branch-id: ${{ steps.project.outputs.branch-id }}
dist-folder: build
project: ${{ secrets.IONOS_PROJECT_ID }}
remote-host: ${{ steps.project.outputs.remote-host }}
service-host: api-us.ionos.space
storage-quota: ${{ steps.project.outputs.storage-quota }}