Skip to content

Commit 696d48b

Browse files
a-bMichael ChinigoGreg Wereschgururajshjoaopapereira
authored
Migrate CF CLI Bosh release to GitHub Action workflow (#19)
- Setup devcontainer-based local environment using cached base image - Use nekto/act to iterate on the pipeline locally - Extract shepherd leasing option into the separate remote action - Implenent machanism to sync GHA variables and secrets between repositories Co-authored-by: Michael Chinigo <[email protected]> Co-authored-by: Greg Weresch <[email protected]> Co-authored-by: Shwetha Gururaj <[email protected]> Co-authored-by: Joao De Almeida Pereira <[email protected]>
1 parent 4e9434d commit 696d48b

39 files changed

+813
-806
lines changed

.changeset/config.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
3+
"changelog": "@changesets/cli/changelog",
4+
"commit": false,
5+
"fixed": [],
6+
"linked": [],
7+
"access": "restricted",
8+
"baseBranch": "main",
9+
"updateInternalDependencies": "patch",
10+
"ignore": []
11+
}

.devcontainer/Dockerfile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
FROM ghcr.io/cloudfoundry/bosh-package-cf-cli-release-ci:main-latest
2+
3+
RUN apt update && apt install --yes \
4+
entr \
5+
fzf \
6+
htop \
7+
neovim
8+
9+
RUN curl --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/nektos/act/master/install.sh | sudo bash

.devcontainer/devcontainer.json

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"name": "Cloudfoundry CLI Bosh Release",
3+
"dockerFile": "Dockerfile",
4+
"features": {
5+
"ghcr.io/devcontainers/features/docker-outside-of-docker:1": {},
6+
"ghcr.io/devcontainers/features/github-cli:1": {},
7+
"ghcr.io/devcontainers/features/sshd:1": {}
8+
},
9+
"customizations": {
10+
"vscode": {
11+
"settings": {},
12+
"extensions": [
13+
"DavidAnson.vscode-markdownlint",
14+
"GitHub.vscode-pull-request-github",
15+
"editorconfig.editorconfig",
16+
"github.vscode-github-actions",
17+
"ms-vscode.makefile-tools",
18+
"ms-vsliveshare.vsliveshare",
19+
"timonwong.shellcheck",
20+
"vmware.vscode-concourse"
21+
]
22+
}
23+
}
24+
}

.editorconfig

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
root = true
2+
3+
[*]
4+
end_of_line = lf
5+
indent_size = 2
6+
indent_style = space
7+
insert_final_newline = true
8+
9+
[Makefile]
10+
indent_style = tab

.github/.secrets

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
AWS_S3_ACCESS_KEY_ID: fake-aws-s3-access-key-id
2+
AWS_S3_ASSUME_ROLE_ARN: fake-aws-s3-assume-role-arn
3+
AWS_S3_SECRET_ACCESS_KEY: fake-aws-s3-secret-access-key
4+
SHEPHERD_API_ENDPOINT: fake-shepherd-api-endpoint
5+
SHEPHERD_API_TOKEN: fake-shepherd-api-token

.github/.vars

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
AWS_S3_REGION: us-east-2
2+
AWS_S3_BUCKET: cf-cli-bosh-release-dev
3+
PRODUCTION: true
4+
# BRANCH_SUFFIX: -shadow
5+
# SKIP_TESTS: false
6+
# ENV_ID:

.github/workflows/README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# GHA Workflows
2+
3+
## [Create Bosh Release](create-bosh-release.yml)
4+
5+
Why? To create a new cf cli bosh release including major cli versions.
6+
7+
### Resources
8+
- [Old Concourse implementation of the release pipeline](https://ci.cli.fun/teams/main/pipelines/cf-cli-release-toolsmiths)
9+
- [pipeline definition](../../ci/pipeline-toolsmiths.yml)
10+
11+
### Plan
12+
13+
- Acquire cf cli linux binaries for v7, and v8 from s3
14+
- Detect latest tag under each major version
15+
16+
- ...
17+
18+
- Upload (where?) newly created cf cli bosh release.
19+
- Update Releases section on GitHub https://github.com/cloudfoundry/bosh-package-cf-cli-release/releases

0 commit comments

Comments
 (0)