Skip to content
This repository was archived by the owner on Sep 9, 2020. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions incubator/tomcat/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* [Quickstart](#quickstart)
* [Using Prototypes](#using-prototypes)
* [io.ksonnet.pkg.stateless-tomcat](#io.ksonnet.pkg.stateless-tomcat)
* [io.ksonnet.pkg.non-persistent-tomcat](#io.ksonnet.pkg.non-persistent-tomcat)
* [io.ksonnet.pkg.persistent-tomcat](#io.ksonnet.pkg.persistent-tomcat)

## Quickstart

Expand All @@ -21,10 +21,10 @@ Finally, in the ksonnet application directory, run the following:
# Expand prototype as a Jsonnet file, place in a file in the
# `components/` directory. (YAML and JSON are also available.)
$ ks prototype use io.ksonnet.pkg.persistent-tomcat tomcat \
--tomcatPassword boots \
--name tomcat \
--namespace default \
--tomcatUser frank
--tomcatUser frank \
--tomcatPassword boots

# Apply to server.
$ ks apply -f tomcat.jsonnet
Expand All @@ -40,8 +40,7 @@ These prototypes, as well as how to use them, are enumerated below.

### io.ksonnet.pkg.stateless-tomcat

Deploys a stateful Tomcat server, backed by a persistent volume. Server isdeployed using a Kubernetes deployment, and exposed to the network using a
service. The password is stored as a secret.
Deploys a stateless Tomcat server. Server is deployed using a Kubernetesdeployment, and exposed to the network using a service. The password is stored as a secret.

#### Example

Expand All @@ -67,19 +66,20 @@ Below is the Jsonnet file generated by this command.
The available options to pass prototype are:

* `--namespace=<namespace>`: Namespace in which to put the application [string]
* `--name=<name>`: Name to give to each of the components [string]
* `--name=<name>`: Name to give to each of the components. [string]
* `--tomcatUser=<tomcatUser>`: Username for tomcat manager page, if not specified tomcat will not assign users [string]
* `--tomcatPassword=<tomcatPassword>`: Tomcat manager page password, to be encrypted and included in Secret API object [string]
### io.ksonnet.pkg.non-persistent-tomcat
### io.ksonnet.pkg.persistent-tomcat

Deploys a stateless Tomcat server. Server is deployed using a Kubernetesdeployment, and exposed to the network using a service. The password is stored as a secret.
When generated and applied this package will create a secret,a deployment, mount a persistent volume claim, & expose the deployment via a
service.

#### Example

```shell
# Expand prototype as a Jsonnet file, place in a file in the
# `components/` directory. (YAML and JSON are also available.)
$ ks prototype use io.ksonnet.pkg.non-persistent-tomcat tomcat \
$ ks prototype use io.ksonnet.pkg.persistent-tomcat tomcat \
--namespace YOUR_NAMESPACE_HERE \
--name YOUR_NAME_HERE \
--tomcatUser YOUR_TOMCATUSER_HERE \
Expand All @@ -98,7 +98,7 @@ Below is the Jsonnet file generated by this command.
The available options to pass prototype are:

* `--namespace=<namespace>`: Namespace in which to put the application [string]
* `--name=<name>`: Name to give to each of the components. [string]
* `--name=<name>`: Name to give to each of the components [string]
* `--tomcatUser=<tomcatUser>`: Username for tomcat manager page, if not specified tomcat will not assign users [string]
* `--tomcatPassword=<tomcatPassword>`: Tomcat manager page password, to be encrypted and included in Secret API object [string]

Expand Down
8 changes: 4 additions & 4 deletions incubator/tomcat/prototypes/tomcat-persistent.jsonnet
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
// @apiVersion 0.1
// @name io.ksonnet.pkg.persistent-tomcat
// @description Deploys a stateful Tomcat server, backed by a persistent volume. Server is
// deployed using a Kubernetes deployment, and exposed to the network using a
// service. The password is stored as a secret.
// @description When generated and applied this package will create a secret,
// a deployment, mount a persistent volume claim, & expose the deployment via a
// service.
// @param namespace string Namespace in which to put the application
// @param name string Name to give to each of the components
// @param tomcatUser string Username for tomcat manager page, if not specified tomcat will not assign users
// @param tomcatPassword string Tomcat manager page password, to be encrypted and included in Secret API object
// @param tomcatPassword string Tomcat manager page password, to be encrypted and included in Secret Object

local k = import 'ksonnet.beta.2/k.libsonnet';
local tc = import 'incubator/tomcat/tomcat.libsonnet';
Expand Down
4 changes: 2 additions & 2 deletions incubator/tomcat/prototypes/tomcat-stateless.jsonnet
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
// @apiVersion 0.0.1
// @name io.ksonnet.pkg.non-persistent-tomcat
// @name io.ksonnet.pkg.stateless-tomcat
// @description Deploys a stateless Tomcat server. Server is deployed using a Kubernetes
// deployment, and exposed to the network using a service. The password is stored as a secret.
// @param namespace string Namespace in which to put the application
// @param name string Name to give to each of the components.
// @param tomcatUser string Username for tomcat manager page, if not specified tomcat will not assign users
// @param tomcatPassword string Tomcat manager page password, to be encrypted and included in Secret API object
// @param tomcatPassword string Tomcat manager page password, to be encrypted and included in Secret Object

local k = import 'ksonnet.beta.2/k.libsonnet';
local tc = import 'incubator/tomcat/tomcat.libsonnet';
Expand Down