Skip to content

Commit 1b92b91

Browse files
authored
feat(action): use render cli
BREAKING CHANGE: This action now uses the Render CLI.
1 parent f0809c0 commit 1b92b91

File tree

14 files changed

+62
-20749
lines changed

14 files changed

+62
-20749
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
name: CI
22

3-
on:
3+
on:
44
push:
5-
branches: [main]
5+
branches: [main, beta]
66
workflow_dispatch:
77

88
permissions: read-all
@@ -20,20 +20,8 @@ jobs:
2020
- name: Checkout for testing preparation
2121
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8
2222

23-
- name: Use Node.js current version
24-
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444
25-
with:
26-
node-version: current
27-
28-
- name: Install package dependencies
29-
run: npm ci
30-
31-
- name: Build the actions
32-
run: npm run build
33-
3423
- name: Test actions for simple action
3524
uses: ./
3625
with:
3726
serviceId: ${{ secrets.RENDER_SERVICE_ID }}
3827
apiKey: ${{ secrets.RENDER_API_KEY }}
39-
multipleDeployment: false #optional, default true

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2021 Scheduling Workbox System
3+
Copyright (c) 2025 Scheduling Workbox System
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,14 @@ jobs:
1515
name: Deploy to Render
1616
runs-on: ubuntu-latest
1717
steps:
18-
- name: Trigger deployment
18+
- name: Checkout code
19+
uses: actions/checkout@main #consider using pin for dependabot auto update
20+
21+
- name: Create deployment
1922
uses: sws2apps/render-deployment@main #consider using pin for dependabot auto update
2023
with:
2124
serviceId: ${{ secrets.RENDER_SERVICE_ID }}
2225
apiKey: ${{ secrets.RENDER_API_KEY }}
23-
multipleDeployment: false #optional, default true
26+
node-version: lts/Iron #optional
27+
cli-version: 2.2.0 #optional
2428
```

SECURITY.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22

33
## Reporting a Vulnerability
44

5-
You can report a vulnerability by contacting us via email at sws2apps.notification@gmail.com. We will try to do our best to respond you and handle the matter as soon as possible.
5+
You can report a vulnerability by contacting us via email at contact@sws2apps.com. We will try to do our best to respond you and handle the matter as soon as possible.

action.yaml

Lines changed: 27 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,36 @@ inputs:
77
required: true
88
apiKey:
99
description: 'Your personal API key to interact with Render'
10+
required: true
11+
node-version:
12+
description: 'NodeJS Version Spec of the version to use. Examples: 12.x, 10.15.1, >=10.15.0., lts/Jod'
1013
required: false
11-
multipleDeployment:
12-
description: 'Specify if having multiple deployment is allowed'
14+
default: 'lts/Jod'
15+
cli-version:
16+
description: 'Render CLI version from GitHub release'
1317
required: false
14-
default: true
18+
default: '2.2.0'
1519
runs:
16-
using: 'node20'
17-
main: 'dist/index.js'
20+
using: 'composite'
21+
steps:
22+
- name: Setup Node.js
23+
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444
24+
with:
25+
node-version: ${{ inputs.node-version }}
26+
27+
- name: Install Render CLI
28+
shell: bash
29+
run: |
30+
curl -fsSL https://raw.githubusercontent.com/render-oss/cli/refs/tags/v${{ inputs.cli-version }}/bin/install.sh | sh
31+
32+
- name: Trigger deploy with Render CLI
33+
shell: bash
34+
env:
35+
RENDER_API_KEY: ${{ inputs.apiKey }}
36+
CI: true
37+
run: |
38+
render deploys create ${{ inputs.serviceId }} --output text --confirm --wait
39+
1840
branding:
1941
icon: 'play-circle'
2042
color: 'purple'

0 commit comments

Comments
 (0)