blob: be7f30e74e62520df3af8b1d719567ccfcc9d635 [file] [log] [blame]
Giorgi Lekveishvilie009a5d2024-01-05 14:10:11 +04001input: {
gioff2a29a2024-05-01 17:06:42 +04002 network: #Network @name(Network)
gio44f621b2024-04-29 09:44:38 +04003 subdomain: string @name(Subdomain)
gioff2a29a2024-05-01 17:06:42 +04004 sshPort: int @name(SSH Port)
gio44f621b2024-04-29 09:44:38 +04005 adminKey: string @name(Admin SSH Public Key)
Giorgi Lekveishvilie009a5d2024-01-05 14:10:11 +04006}
7
8_domain: "\(input.subdomain).\(global.privateDomain)"
9
Giorgi Lekveishvilief21c132024-01-17 18:57:58 +040010name: "Soft-Serve"
11namespace: "app-soft-serve"
12// TODO(gio): make public network an option
13readme: "softserve application will be installed on private network and be accessible to any user on https://\(_domain)"
14description: "A tasty, self-hostable Git server for the command line. 🍦"
15icon: "<svg xmlns='http://www.w3.org/2000/svg' width='50' height='50' viewBox='0 0 48 48'><g fill='none' stroke='currentColor' stroke-linecap='round' stroke-width='4'><path stroke-linejoin='round' d='M15.34 22.5L21 37l3 6l3-6l5.66-14.5'/><path d='M19 32h10'/><path stroke-linejoin='round' d='M24 3c-6 0-8 6-8 6s-6 2-6 7s5 7 5 7s3.5-2 9-2s9 2 9 2s5-2 5-7s-6-7-6-7s-2-6-8-6Z'/></g></svg>"
Giorgi Lekveishvilie009a5d2024-01-05 14:10:11 +040016
17images: {
18 softserve: {
19 repository: "charmcli"
20 name: "soft-serve"
21 tag: "v0.7.1"
22 pullPolicy: "IfNotPresent"
23 }
24}
25
26charts: {
27 softserve: {
28 chart: "charts/soft-serve"
29 sourceRef: {
30 kind: "GitRepository"
31 name: "pcloud"
32 namespace: global.id
33 }
34 }
35}
36
gioff2a29a2024-05-01 17:06:42 +040037ingress: {
38 gerrit: {
39 auth: enabled: false
40 network: input.network
41 subdomain: input.subdomain
42 service: {
43 name: "soft-serve"
44 port: number: 80
45 }
46 }
47}
48
49portForward: [#PortForward & {
50 allocator: input.network.allocatePortAddr
51 sourcePort: input.sshPort
52 // TODO(gio): namespace part must be populated by app manager. Otherwise
53 // third-party app developer might point to a service from different namespace.
54 targetService: "\(release.namespace)/soft-serve"
55 targetPort: 22
56}]
57
Giorgi Lekveishvilie009a5d2024-01-05 14:10:11 +040058helm: {
59 softserve: {
60 chart: charts.softserve
61 values: {
gioff2a29a2024-05-01 17:06:42 +040062 serviceType: "ClusterIP"
Giorgi Lekveishvilie009a5d2024-01-05 14:10:11 +040063 adminKey: input.adminKey
gioff2a29a2024-05-01 17:06:42 +040064 sshPublicPort: input.sshPort
Giorgi Lekveishvilie009a5d2024-01-05 14:10:11 +040065 ingress: {
66 enabled: false
gioff2a29a2024-05-01 17:06:42 +040067 domain: _domain
Giorgi Lekveishvilie009a5d2024-01-05 14:10:11 +040068 }
69 image: {
70 repository: images.softserve.fullName
71 tag: images.softserve.tag
72 pullPolicy: images.softserve.pullPolicy
73 }
74 }
75 }
76}
gioff2a29a2024-05-01 17:06:42 +040077
78help: [{
79 title: "Access"
80 contents: """
81 SSH CLI: ssh \(_domain) -p \(input.sshPort) help
82 SSH TUI: ssh \(_domain) -p \(input.sshPort)
83 HTTP: git clone https://\(_domain)/<REPO-NAME>
84 SSH: git clone ssh://\(_domain):\(input.sshPort)/<REPO-NAME>
85
86 See following resource on what you can do with Soft-Serve TUI: [https://github.com/charmbracelet/soft-serve](https://github.com/charmbracelet/soft-serve)
87 """
88}]