|
1 |
| -# go-bootstrap |
| 1 | +# Kubernetes Service CA controller |
2 | 2 |
|
3 |
| -[][build] |
4 |
| - |
5 |
| -[][releases] |
6 |
| -[][codeclimate] |
7 |
| -[][codeclimate] |
8 |
| -[][releases] |
| 3 | +[][build] |
| 4 | + |
| 5 | +[][releases] |
| 6 | +[][codeclimate] |
| 7 | +[][codeclimate] |
| 8 | +[][releases] |
9 | 9 |
|
10 |
| -[build]: https://github.com/vshn/go-bootstrap/actions?query=workflow%3ATest |
11 |
| -[releases]: https://github.com/vshn/go-bootstrap/releases |
12 |
| -[codeclimate]: https://codeclimate.com/github/vshn/go-bootstrap |
| 10 | +[build]: https://github.com/projectsyn/k8s-service-ca-controller/actions?query=workflow%3ATest |
| 11 | +[releases]: https://github.com/projectsyn/k8s-service-ca-controller/releases |
| 12 | +[codeclimate]: https://codeclimate.com/github/projectsyn/k8s-service-ca-controller |
13 | 13 |
|
14 |
| -Template repository for common Go setups |
15 |
| - |
16 |
| -## Features |
17 |
| - |
18 |
| -* GitHub Workflows |
19 |
| - - Build (Go & Docker image) |
20 |
| - - Test (including CodeClimate) |
21 |
| - - Lint (Go) |
22 |
| - - Release (Goreleaser & Changelog generator) |
23 |
| - |
24 |
| -* GitHub issue templates |
25 |
| - - PR template |
26 |
| - - Issue templates using GitHub issue forms |
27 |
| - |
28 |
| -* Goreleaser |
29 |
| - - Go build for `amd64`, `armv8` |
30 |
| - - Docker build for `latest` and `vx.y.z` tags |
31 |
| - - Push Docker image to GitHub's registry `ghcr.io` |
32 |
| - |
33 |
| -* Antora documentation |
34 |
| - - Build default documentation with VSHN styling |
35 |
| - - Publish to GitHub Pages by default (opt-out) |
36 |
| - - Automated with GitHub workflows to build in `master` branch and (pre-)releases. |
37 |
| - - Available `make` targets are prefixed with `docs-` |
38 |
| - |
39 |
| -* Local Kubernetes environment |
40 |
| - - Setup Kubernetes-In-Docker (kind) |
41 |
| - - Prepares a kubeconfig file in `.kind/` |
42 |
| - - Optionally install NGINX as ingress controller |
43 |
| - - Available `make` targets are prefixed with `kind-` |
44 |
| - |
45 |
| -* CLI and logging framework |
46 |
| - - To help get you started with CLI subcommands, flags and environment variables |
47 |
| - - If you don't need subcommands, remove `example_command.go` and adjust `cli.App` settings in `main.go` |
48 |
| - |
49 |
| -## TODO's after generating from this template |
50 |
| - |
51 |
| -TIP: You can search for these tasks using `grep -n -r "TODO:" .` |
52 |
| - |
53 |
| -1. `go.mod`: Adjust module name. |
54 |
| -1. `.goreleaser.yml`: Adjust Docker image location in `dockers` and `docker_manifests` parameters. |
55 |
| -1. `.gitignore`: Adjust binary file name. |
56 |
| -1. `Dockerfile`: Adjust binary file name. |
57 |
| -1. `Makefile.vars.mk`: Adjust project meta. |
58 |
| -1. `.github/ISSUE_TEMPLATE/config.yml` (optional): Enable forwarding questions to GitHub Discussions or other page. |
59 |
| -1. `.github/workflows/test.yml`: Update CodeClimate reporter ID (to be found in codeclimate.com Test coverage settings) |
60 |
| -1. `docs/antora.yml`: Adjust project meta. |
61 |
| -1. `docs/antora-playbook.yml`: Adjust project meta. |
62 |
| -1. `docs/modules/pages/index.adoc`: Edit start page. |
63 |
| -1. `docs/modules/nav.adoc`: Edit navigation. |
64 |
| -1. `main.go`: Adjust variables. |
65 |
| -1. Edit this README (including badges links) |
66 |
| -1. Start hacking in `example_command.go`. |
67 |
| - |
68 |
| -After completing a task, you can remove the comment in the files. |
69 |
| - |
70 |
| -## Other repository settings |
71 |
| - |
72 |
| -1. GitHub Settings |
73 |
| - - "Options > Wiki" (disable) |
74 |
| - - "Options > Allow auto-merge" (enable) |
75 |
| - - "Options > Automatically delete head branches" (enable) |
76 |
| - - "Collaborators & Teams > Add Teams and users to grant maintainer permissions |
77 |
| - - "Branches > Branch protection rules": |
78 |
| - - Branch name pattern: `master` |
79 |
| - - Require status check to pass before merging: `["lint"]` (you may need to push come commits first) |
80 |
| - - "Pages > Source": Branch `gh-pages` |
81 |
| - |
82 |
| -1. GitHub Issue labels |
83 |
| - - "Issues > Labels > New Label" for the following labels with color suggestions: |
84 |
| - - `change` (`#D93F0B`) |
85 |
| - - `dependency` (`#ededed`) |
86 |
| - - `breaking` (`#FBCA04`) |
87 |
| - |
88 |
| -1. CodeClimate Settings |
89 |
| - - "Repo Settings > GitHub > Pull request status updates" (install) |
90 |
| - - "Repo Settings > Test coverage > Enforce {Diff,Total} Coverage" (configure to your liking) |
91 |
| - |
92 |
| -## Antora documentation |
93 |
| - |
94 |
| -This template comes with an Antora documentation module to help you create Asciidoctor documentation. |
95 |
| -By default, it is automatically published to GitHub Pages in `gh-pages` branch, however it can also be included in external Antora playbooks. |
96 |
| - |
97 |
| -### Setup GitHub Pages |
98 |
| - |
99 |
| -Once you generated a new repository using this template, the initial commit automatically runs a Job that creates the documentation in the `gh-pages` branch. |
100 |
| -All you need to do is then to enable Pages in the settings. |
101 |
| - |
102 |
| -The `gh-pages` branch is a parent-less commit that only contains the Antora-generated files. |
103 |
| - |
104 |
| -However, if that's not the case or if you are setting up Antora in an existing repository, here's how you can achieve the same, but make sure to **commit or stash current changes first!** |
105 |
| -```bash |
106 |
| -current_branch=$(git rev-parse --abbrev-ref HEAD) |
107 |
| -initial_commit=$(git rev-list --max-parents=0 HEAD) |
108 |
| -git switch --create gh-pages $initial_commit |
109 |
| -git rm -r --cached . |
110 |
| -git commit -m "Prepare gh-pages branch" |
111 |
| -git push --set-upstream origin gh-pages |
112 |
| -git switch -f $current_branch |
113 |
| -``` |
114 |
| - |
115 |
| -And you're done! |
116 |
| -GitHub automatically recognizes activity and sets up Pages if there's a `gh-pages` branch. |
117 |
| - |
118 |
| ---- |
119 |
| - |
120 |
| -If you want to skip deployment to GitHub Pages you need to delete specific files and references: |
121 |
| -`rm -f .github/workflows/docs.yml docs/package*.json docs/antora-playbook.yml docs/antora-build.mk`. |
122 |
| -Also don't forget to delete the branch and disable Pages in the repository settings. |
123 |
| - |
124 |
| ---- |
125 |
| - |
126 |
| -If you want to remove documentation completely simply run `rm -rf docs .github/workflows/docs.yml`. |
| 14 | +The Kubernetes Service CA controller issues certificates for Services labelled with `service.syn.tools/serving-cert-secret-name`. |
| 15 | +The controller uses [cert-manager] for the actual certificate issuing and copies the generated certificate secret into the service namespace. |
0 commit comments