Skip to content

Commit 596cbf6

Browse files
committed
feat: add docs and now update configuration
Signed-off-by: will <[email protected]>
1 parent 58783f2 commit 596cbf6

File tree

20 files changed

+20065
-4
lines changed

20 files changed

+20065
-4
lines changed

config/manager/kustomization.yaml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,3 @@ images:
66
- name: controller
77
newName: wcrum/imageshift
88
newTag: latest
9-
- name: wcrum/imageshift
10-
newName: wcrum/imageshift
11-
newTag: latest

config/manager/manager.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ spec:
6363
args:
6464
- --leader-elect
6565
- --health-probe-bind-address=:8081
66-
image: wcrum/imageshift:latest
66+
image: controller:latest
6767
name: manager
6868
ports: []
6969
securityContext:

docs/.gitignore

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Dependencies
2+
node_modules/
3+
4+
# Build output
5+
build/
6+
7+
# Docusaurus cache
8+
.docusaurus/
9+
10+
# Misc
11+
.DS_Store
12+
*.log
13+
npm-debug.log*
14+
yarn-debug.log*
15+
yarn-error.log*

docs/docs/installation/helm.md

Lines changed: 145 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,145 @@
1+
---
2+
sidebar_position: 3
3+
---
4+
5+
# Helm Installation
6+
7+
Install ImageShift using Helm for a customizable deployment.
8+
9+
## Install ImageShift
10+
11+
ImageShift is distributed as an OCI Helm chart. No `helm repo add` is required.
12+
13+
Basic installation:
14+
15+
```bash
16+
helm install imageshift oci://ghcr.io/wcrum/imageshift/chart \
17+
--version <version> \
18+
-n imageshift-system \
19+
--create-namespace
20+
```
21+
22+
With custom values:
23+
24+
```bash
25+
helm install imageshift oci://ghcr.io/wcrum/imageshift/chart \
26+
--version <version> \
27+
-n imageshift-system \
28+
--create-namespace \
29+
-f values.yaml
30+
```
31+
32+
## Configuration Values
33+
34+
The following table lists the configurable parameters of the ImageShift chart.
35+
36+
### Global Settings
37+
38+
| Parameter | Description | Default |
39+
|-----------|-------------|---------|
40+
| `replicaCount` | Number of controller replicas | `1` |
41+
| `image.repository` | Controller image repository | `ghcr.io/wcrum/imageshift` |
42+
| `image.tag` | Controller image tag | `latest` |
43+
| `image.pullPolicy` | Image pull policy | `IfNotPresent` |
44+
| `imagePullSecrets` | Image pull secrets | `[]` |
45+
| `nameOverride` | Override chart name | `""` |
46+
| `fullnameOverride` | Override full release name | `""` |
47+
48+
### Controller Settings
49+
50+
| Parameter | Description | Default |
51+
|-----------|-------------|---------|
52+
| `controller.resources.limits.cpu` | CPU limit | `500m` |
53+
| `controller.resources.limits.memory` | Memory limit | `128Mi` |
54+
| `controller.resources.requests.cpu` | CPU request | `10m` |
55+
| `controller.resources.requests.memory` | Memory request | `64Mi` |
56+
| `controller.nodeSelector` | Node selector labels | `{}` |
57+
| `controller.tolerations` | Pod tolerations | `[]` |
58+
| `controller.affinity` | Pod affinity rules | `{}` |
59+
60+
### Webhook Settings
61+
62+
| Parameter | Description | Default |
63+
|-----------|-------------|---------|
64+
| `webhook.port` | Webhook server port | `9443` |
65+
| `webhook.certManager.enabled` | Use cert-manager for TLS | `true` |
66+
| `webhook.certManager.issuerRef` | cert-manager issuer reference | `{}` |
67+
68+
### RBAC Settings
69+
70+
| Parameter | Description | Default |
71+
|-----------|-------------|---------|
72+
| `rbac.create` | Create RBAC resources | `true` |
73+
| `serviceAccount.create` | Create service account | `true` |
74+
| `serviceAccount.name` | Service account name | `""` |
75+
| `serviceAccount.annotations` | Service account annotations | `{}` |
76+
77+
## Example values.yaml
78+
79+
```yaml
80+
replicaCount: 2
81+
82+
image:
83+
repository: ghcr.io/wcrum/imageshift
84+
tag: v1.0.0
85+
pullPolicy: IfNotPresent
86+
87+
controller:
88+
resources:
89+
limits:
90+
cpu: 500m
91+
memory: 256Mi
92+
requests:
93+
cpu: 100m
94+
memory: 128Mi
95+
96+
nodeSelector:
97+
kubernetes.io/os: linux
98+
99+
tolerations:
100+
- key: "node-role.kubernetes.io/control-plane"
101+
operator: "Exists"
102+
effect: "NoSchedule"
103+
104+
webhook:
105+
port: 9443
106+
certManager:
107+
enabled: true
108+
109+
rbac:
110+
create: true
111+
112+
serviceAccount:
113+
create: true
114+
annotations:
115+
eks.amazonaws.com/role-arn: arn:aws:iam::123456789012:role/imageshift-role
116+
```
117+
118+
## Upgrade
119+
120+
To upgrade an existing installation:
121+
122+
```bash
123+
helm upgrade imageshift oci://ghcr.io/wcrum/imageshift/chart \
124+
--version <version> \
125+
-n imageshift-system
126+
```
127+
128+
## Uninstall
129+
130+
To remove ImageShift:
131+
132+
```bash
133+
helm uninstall imageshift -n imageshift-system
134+
```
135+
136+
Note: This will not remove the CRDs. To remove CRDs:
137+
138+
```bash
139+
kubectl delete crd imageshifts.imageshift.dev
140+
```
141+
142+
## Next Steps
143+
144+
- [CRD Reference](../reference/crd) - Configure your Imageshift resource
145+
- [Configuration Examples](../reference/configuration) - Real-world configuration examples
Lines changed: 176 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,176 @@
1+
---
2+
sidebar_position: 4
3+
---
4+
5+
# Kustomize Installation
6+
7+
Install ImageShift using Kustomize for GitOps-friendly deployments.
8+
9+
## Quick Install
10+
11+
Install directly from the repository:
12+
13+
```bash
14+
kubectl apply -k https://github.com/wcrum/imageshift/config/default
15+
```
16+
17+
## Install from Source
18+
19+
Clone the repository and install:
20+
21+
```bash
22+
git clone https://github.com/wcrum/imageshift.git
23+
cd imageshift
24+
make install # Install CRDs
25+
make deploy # Deploy controller
26+
```
27+
28+
## Kustomize Structure
29+
30+
The ImageShift repository provides the following Kustomize bases:
31+
32+
```
33+
config/
34+
├── crd/ # Custom Resource Definitions
35+
├── rbac/ # RBAC permissions
36+
├── manager/ # Controller deployment
37+
├── webhook/ # Webhook configuration
38+
├── certmanager/ # cert-manager integration
39+
└── default/ # Complete installation
40+
```
41+
42+
## Creating a Custom Overlay
43+
44+
Create your own overlay to customize the installation:
45+
46+
```
47+
my-imageshift/
48+
├── kustomization.yaml
49+
└── patches/
50+
└── manager-resources.yaml
51+
```
52+
53+
### kustomization.yaml
54+
55+
```yaml
56+
apiVersion: kustomize.config.k8s.io/v1beta1
57+
kind: Kustomization
58+
59+
namespace: imageshift-system
60+
61+
resources:
62+
- https://github.com/wcrum/imageshift/config/default
63+
64+
patches:
65+
- path: patches/manager-resources.yaml
66+
```
67+
68+
### patches/manager-resources.yaml
69+
70+
```yaml
71+
apiVersion: apps/v1
72+
kind: Deployment
73+
metadata:
74+
name: controller-manager
75+
namespace: imageshift-system
76+
spec:
77+
replicas: 2
78+
template:
79+
spec:
80+
containers:
81+
- name: manager
82+
resources:
83+
limits:
84+
cpu: 500m
85+
memory: 256Mi
86+
requests:
87+
cpu: 100m
88+
memory: 128Mi
89+
```
90+
91+
Apply your overlay:
92+
93+
```bash
94+
kubectl apply -k my-imageshift/
95+
```
96+
97+
## Common Customizations
98+
99+
### Change Namespace
100+
101+
```yaml
102+
apiVersion: kustomize.config.k8s.io/v1beta1
103+
kind: Kustomization
104+
105+
namespace: custom-namespace
106+
107+
resources:
108+
- https://github.com/wcrum/imageshift/config/default
109+
```
110+
111+
### Add Image Pull Secrets
112+
113+
```yaml
114+
apiVersion: kustomize.config.k8s.io/v1beta1
115+
kind: Kustomization
116+
117+
resources:
118+
- https://github.com/wcrum/imageshift/config/default
119+
120+
patches:
121+
- target:
122+
kind: Deployment
123+
name: controller-manager
124+
patch: |
125+
- op: add
126+
path: /spec/template/spec/imagePullSecrets
127+
value:
128+
- name: my-registry-secret
129+
```
130+
131+
### Use a Specific Image Version
132+
133+
```yaml
134+
apiVersion: kustomize.config.k8s.io/v1beta1
135+
kind: Kustomization
136+
137+
resources:
138+
- https://github.com/wcrum/imageshift/config/default
139+
140+
images:
141+
- name: controller
142+
newName: ghcr.io/wcrum/imageshift
143+
newTag: v1.0.0
144+
```
145+
146+
## Development Installation
147+
148+
For local development:
149+
150+
```bash
151+
# Create a kind cluster
152+
kind create cluster --name imageshift-dev
153+
154+
# Install CRDs only
155+
make install
156+
157+
# Run the controller locally (outside the cluster)
158+
make run
159+
```
160+
161+
## Uninstall
162+
163+
To remove ImageShift:
164+
165+
```bash
166+
# Remove controller and webhooks
167+
kubectl delete -k https://github.com/wcrum/imageshift/config/default
168+
169+
# Remove CRDs (optional)
170+
kubectl delete -k https://github.com/wcrum/imageshift/config/crd
171+
```
172+
173+
## Next Steps
174+
175+
- [CRD Reference](../reference/crd) - Configure your Imageshift resource
176+
- [Configuration Examples](../reference/configuration) - Real-world configuration examples

0 commit comments

Comments
 (0)