Skip to content

Commit 447ca1a

Browse files
authored
Support Package Refresh 2024-11 (#17)
- Updated Deno Version - Resolved #16 and added option to select namespace if no runtime exists - Switch to GitHub Actions - Added Support Version in the Package - Limit concurrency to 5 processes for certain items.
1 parent 2d62fa2 commit 447ca1a

File tree

18 files changed

+898
-901
lines changed

18 files changed

+898
-901
lines changed

.devcontainer/devcontainer.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// For format details, see https://aka.ms/devcontainer.json.
22
{
33
"name": "Codefresh Support Package",
4-
"image": "denoland/deno:2.0.3",
5-
"onCreateCommand": "apt-get update && apt-get install git zip -y",
4+
"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
5+
"onCreateCommand": "curl -fsSL https://deno.land/install.sh | sh -s -- -y",
66
"customizations": {
77
"vscode": {
88
"settings": {
@@ -11,7 +11,8 @@
1111
},
1212
"extensions": [
1313
"denoland.vscode-deno",
14-
"davidanson.vscode-markdownlint"
14+
"davidanson.vscode-markdownlint",
15+
"redhat.vscode-yaml"
1516
]
1617
}
1718
}

.github/workflows/release.yaml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*' # Triggers the workflow on new tags that start with 'v'
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Checkout repository
14+
uses: actions/checkout@v2
15+
16+
- name: Set up Deno
17+
uses: denoland/setup-deno@v2
18+
with:
19+
deno-version: vx.x.x
20+
21+
- name: Compile binaries
22+
run: |
23+
sed -i "s/__APP_VERSION__/$TAG_NAME/g" main.js
24+
deno task compile
25+
env:
26+
TAG_NAME: ${{ github.ref_name }}
27+
28+
- name: Package binaries
29+
run: |
30+
zip ./bin/cf-support_windows_x86_64.zip ./bin/cf-support_windows_x86_64.exe
31+
tar -czvf ./bin/cf-support_darwin_x86_64.tar.gz ./bin/cf-support_darwin_x86_64
32+
tar -czvf ./bin/cf-support_darwin_arm64.tar.gz ./bin/cf-support_darwin_arm64
33+
tar -czvf ./bin/cf-support_linux_x86_64.tar.gz ./bin/cf-support_linux_x86_64
34+
35+
- name: Create GitHub Release
36+
id: create_release
37+
uses: ncipollo/release-action@v1
38+
with:
39+
artifacts: |
40+
./bin/cf-support_windows_x86_64.zip
41+
./bin/cf-support_darwin_x86_64.tar.gz
42+
./bin/cf-support_darwin_arm64.tar.gz
43+
./bin/cf-support_linux_x86_64.tar.gz
44+
token: ${{ secrets.GITHUB_TOKEN }}
45+
tag: ${{ github.ref_name }}
46+
name: ${{ github.ref_name }}
47+
body: ${{ github.event.head_commit.message }}
48+
draft: false
49+
prerelease: false

CONTRIBUTIONS.md

Lines changed: 0 additions & 40 deletions
This file was deleted.

README.md

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
# Codefresh Support Package
22

3-
This project is designed to gather data from Hybrid Runtimes for Codefresh SaaS platform, and Hybrid Runtimes and OnPrem isntallation on the OnPrem Platform. It
4-
collects information about various Kubernetes resources such as Pods, Nodes, Configmaps, Services, and Events. For Classic and OnPrem we gather some informtion
5-
from the platform itself.
3+
This project is designed to gather data from Hybrid Runtimes for Codefresh SaaS platform, and Hybrid Runtimes and OnPrem isntallation on the OnPrem Platform. It collects information about various Kubernetes resources such as Pods, Nodes, Configmaps, Services, and Events. For Classic and OnPrem we gather some informtion from the platform itself.
64

75
## Prereqs
86

@@ -15,9 +13,6 @@ from the platform itself.
1513
- `CF_URL`: URL of the platform (ex: `https://g.codefresh.io`)
1614
- Need an Account Admin Token for Claasic Hybrid Runtime.
1715
- Need a System Admin Token for the OnPrem Installation.
18-
- Helm
19-
- Version 3.
20-
- Used to get the helm release version of the installation.
2116
- JQ
2217
- Used only to get the latest version of the binary for *nix systems.
2318

@@ -76,10 +71,3 @@ chmod +x cf-support
7671
1. Go the the [Latest](https://github.com/codefresh-support/codefresh-support-package/releases/latest) release.
7772
1. Download the cf-support_windows_x86_64.zip file
7873
1. Run the `.exe` file via CMD or PowerShell
79-
80-
## Exit Codes
81-
82-
- 10 - Failed to get codefresh credentials. Please set the enviroment variables (CF_API_KEY and CF_BASE_URL) or make sure you have a valid codefresh config file.
83-
- 20 - Failed to Create Demo Pipeline / Project or Failed to run Demo Pipeline.
84-
- 30 - Failed to Delete Demo Pipeline / Project
85-
- 40 - Invalid Runtime Type. ex: Selecting On-Prem for a SaaS Account.

VERSION

Lines changed: 0 additions & 1 deletion
This file was deleted.

ci/codefresh.yaml

Lines changed: 0 additions & 46 deletions
This file was deleted.

deno.json

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,18 @@
1212
},
1313
"tasks": {
1414
"pre-compile": "rm -rf ./bin && mkdir ./bin",
15-
"compile:linux": "deno compile --config=./deno.json --allow-env --allow-read --allow-write --allow-net --unsafely-ignore-certificate-errors --allow-run --output=./bin/cf-support_linux_x86_64 --target=x86_64-unknown-linux-gnu ./src/main.ts",
16-
"compile:windows": "deno compile --config=./deno.json --allow-env --allow-read --allow-write --allow-net --unsafely-ignore-certificate-errors --allow-run --output=./bin/cf-support_windows_x86_64 --target=x86_64-pc-windows-msvc ./src/main.ts",
17-
"compile:apple": "deno compile --config=./deno.json --allow-env --allow-read --allow-write --allow-net --unsafely-ignore-certificate-errors --allow-run --output=./bin/cf-support_darwin_x86_64 --target=x86_64-apple-darwin ./src/main.ts",
18-
"compile:apple_arm64": "deno compile --config=./deno.json --allow-env --allow-read --allow-write --allow-net --unsafely-ignore-certificate-errors --allow-run --output=./bin/cf-support_darwin_arm64 --target=aarch64-apple-darwin ./src/main.ts",
15+
"compile:linux": "deno compile --config=./deno.json --allow-env --allow-read --allow-write --allow-net --unsafely-ignore-certificate-errors --allow-run --output=./bin/cf-support_linux_x86_64 --target=x86_64-unknown-linux-gnu ./main.js",
16+
"compile:windows": "deno compile --config=./deno.json --allow-env --allow-read --allow-write --allow-net --unsafely-ignore-certificate-errors --allow-run --output=./bin/cf-support_windows_x86_64 --target=x86_64-pc-windows-msvc ./main.js",
17+
"compile:apple": "deno compile --config=./deno.json --allow-env --allow-read --allow-write --allow-net --unsafely-ignore-certificate-errors --allow-run --output=./bin/cf-support_darwin_x86_64 --target=x86_64-apple-darwin ./main.js",
18+
"compile:apple_arm64": "deno compile --config=./deno.json --allow-env --allow-read --allow-write --allow-net --unsafely-ignore-certificate-errors --allow-run --output=./bin/cf-support_darwin_arm64 --target=aarch64-apple-darwin ./main.js",
1919
"compile": "deno task pre-compile && deno task compile:linux && deno task compile:windows && deno task compile:apple && deno task compile:apple_arm64"
2020
},
2121
"imports": {
2222
"@cliffy/table": "jsr:@cliffy/[email protected]",
2323
"@cloudydeno/kubernetes-apis": "jsr:@cloudydeno/kubernetes-apis@^0.5.2",
2424
"@cloudydeno/kubernetes-client": "jsr:@cloudydeno/kubernetes-client@^0.7.3",
2525
"@fakoua/zip-ts": "jsr:@fakoua/zip-ts@^1.3.1",
26+
"@henrygd/semaphore": "jsr:@henrygd/semaphore@^0.0.2",
2627
"@std/encoding": "jsr:@std/encoding@^1.0.5",
2728
"@std/yaml": "jsr:@std/yaml@^1.0.5",
2829
"pako": "npm:pako@^2.1.0"

deno.lock

Lines changed: 109 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)