This k2space.sh
shell script simplifies the creation and deletion of Fabric. You can also use it to list and get information about existing Fabric spaces using:
Usage: `./k2space.sh COMMAND [OPTIONS] SPACE_NAME`
Docker Compose: Running k2space.sh on Microsoft Windows
The
k2space.sh
file is abash
script. A Windows PowerShell-compatible script is not yet available. To run thek2space.sh
script, start theGit Bash
application offered by Git. UsingGit Bash
you can run the script after changing the directory to its location.If you have Git integration enabled within Windows Explorer, you can also start
Git Bash
from Windows Explorer by navigating to the script's directory, right-clicking within the Explorer's window, and selecting 'Show more options'. This will display an 'Open Git Bash here' menu item that can be used to startGit Bash
to runk2start.sh
.
Listing your Spaces
List all Fabric spaces, along with some information such as profile, status (running / stopped), Web Studio port, and the URL that can be used for accessing Web Studio if Traefik is running.
Use:
./k2space.sh list
Creating Additional Spaces
Launch a Fabric space - spacename (optionally, with the selected space profile).
Use:
./k2space.sh create [--profile=profile-name] spacename
After creating your first Space, you will need to wait for Fabric to come up. Unless it's up, you may get a 404 error if Traefik hasn't yet processed its new ingress rules, which may take a few seconds. Otherwise, you might get a 502 error if Traefik is ready but Fabric is not yet ready. Give it some time.
Starting a Space
To start a Fabric space use:
./k2space.sh start spacename
Stopping a Space
To stop a Fabric space use:
./k2space.sh stop spacename
Destroying a Space
Delete the Fabric space - spacename.
This act will not delete the persistent files created by Web Studio and your database(s). You must manually delete them; they are located in the persistent-data/spacename
directory.
Use:
./k2space.sh destroy spacename
Traefik starts automatically after you create your first Fabric space. It will also check whenever a new Fabric space is created. If Traefik is not running, it will be started automatically.
Note: Traefik relies on the Docker network created during the creation of a Fabric space. Therefore, it must be started after the Fabric space.
To restart Traefik (e.g., after configuring your TLS certificates), run the command below:
Using Docker Compose:
docker compose -f k2vingress-compose.yaml restart
Using Podman:
podman compose -f k2vingress-compose.yaml restart
You are ready to add users. You can experiment with the built-in System DB (e.g., Postgres or Cassandra data stores). We recommend using alternate authentication providers rather than using built-in providers.
To use the built-in authentication provider, navigate to the Web Admin App. Select the Security tab. Select the Users tab and add a user. Select the Roles tab, create a new role (e.g., User), and then assign Fabric permissions to the newly created role.
The K2view Fabric Web Studio employs underlying Fabric security capabilities and configurations. Fabric works with several authentication providers. Each authenticator is responsible for handling user authentication and managing user IDs and roles.
The following are the supported authentication providers as described here.
Here are the command options for k2space.sh
:
These configuration files contain required or custom settings used by Fabric. Configure parameters as if you were editing any "ini" file to update config.ini
[section1]
key1=value1
key2=value2
[section2]
key1=value1
key2=value2
This temporary container sets the proper ownership of the persistent data's Space folder. After its execution, it should exit automatically.
K2view Fabric Web Studio's Docker Compose Runtime supports per-Space configuration overrides using custom .env
, compose.yaml
, and .config
files. When a new Fabric Space is created using the k2space.sh
script, the runtime checks for specially named files corresponding to the Space name and applies them accordingly.
When creating a Space named, for example, dcr210
, the following behavior applies:
.env
and .config
files are appended to the base configuration.compose.yaml
files are overridden completely if a matching file is found..env
Customization.env
file is always loaded first..env-dcr210
exists (where dcr210
is the Space name), its values will be appended to or override those defined in the base .env
.MAX_HEAP
, GIT_REPO
, or other custom variables..env
file's FABRIC_VERSION
parameter. Please contact your K2view representative if you'd like to use a later version of Fabric.compose.yaml
Customizationcompose.yaml
is loaded unless a file named compose-dcr210.yaml
exists.compose-dcr210.yaml
exists (where dcr210
is the Space name), it will completely replace the default compose.yaml
for that Space..config
Customizationcommon.config
file is always loaded.dcr210.config
exists (where dcr210
is the Space name), its values will be appended to or override settings from common.config
.You can also explicitly specify files when using the k2space.sh
script:
./k2space.sh create --env=custom.env --compose=custom-compose.yaml --config=custom.config dcr210
When using the --env
or --compose
options, automatic detection of .env-[spacename]
and compose-[spacename].yaml
is skipped.
For a Space named dcr210
, you might create:
.env-dcr210
to override heap size: MAX_HEAP=8G
compose-dcr210.yaml
to expose an additional port (e.g., JDBC port 5124):
```yaml ports:
- `dcr210.config` to point to a different System DB path or define SSO behavior:
ini [System] db.path=/custom/path/system.db ```
This flexible mechanism supports both shared and isolated runtime customization for Fabric Web Studio Spaces, making it ideal for multi-tenant development, QA, or demo environments.
This k2space.sh
shell script simplifies the creation and deletion of Fabric. You can also use it to list and get information about existing Fabric spaces using:
Usage: `./k2space.sh COMMAND [OPTIONS] SPACE_NAME`
Docker Compose: Running k2space.sh on Microsoft Windows
The
k2space.sh
file is abash
script. A Windows PowerShell-compatible script is not yet available. To run thek2space.sh
script, start theGit Bash
application offered by Git. UsingGit Bash
you can run the script after changing the directory to its location.If you have Git integration enabled within Windows Explorer, you can also start
Git Bash
from Windows Explorer by navigating to the script's directory, right-clicking within the Explorer's window, and selecting 'Show more options'. This will display an 'Open Git Bash here' menu item that can be used to startGit Bash
to runk2start.sh
.
Listing your Spaces
List all Fabric spaces, along with some information such as profile, status (running / stopped), Web Studio port, and the URL that can be used for accessing Web Studio if Traefik is running.
Use:
./k2space.sh list
Creating Additional Spaces
Launch a Fabric space - spacename (optionally, with the selected space profile).
Use:
./k2space.sh create [--profile=profile-name] spacename
After creating your first Space, you will need to wait for Fabric to come up. Unless it's up, you may get a 404 error if Traefik hasn't yet processed its new ingress rules, which may take a few seconds. Otherwise, you might get a 502 error if Traefik is ready but Fabric is not yet ready. Give it some time.
Starting a Space
To start a Fabric space use:
./k2space.sh start spacename
Stopping a Space
To stop a Fabric space use:
./k2space.sh stop spacename
Destroying a Space
Delete the Fabric space - spacename.
This act will not delete the persistent files created by Web Studio and your database(s). You must manually delete them; they are located in the persistent-data/spacename
directory.
Use:
./k2space.sh destroy spacename
Traefik starts automatically after you create your first Fabric space. It will also check whenever a new Fabric space is created. If Traefik is not running, it will be started automatically.
Note: Traefik relies on the Docker network created during the creation of a Fabric space. Therefore, it must be started after the Fabric space.
To restart Traefik (e.g., after configuring your TLS certificates), run the command below:
Using Docker Compose:
docker compose -f k2vingress-compose.yaml restart
Using Podman:
podman compose -f k2vingress-compose.yaml restart
You are ready to add users. You can experiment with the built-in System DB (e.g., Postgres or Cassandra data stores). We recommend using alternate authentication providers rather than using built-in providers.
To use the built-in authentication provider, navigate to the Web Admin App. Select the Security tab. Select the Users tab and add a user. Select the Roles tab, create a new role (e.g., User), and then assign Fabric permissions to the newly created role.
The K2view Fabric Web Studio employs underlying Fabric security capabilities and configurations. Fabric works with several authentication providers. Each authenticator is responsible for handling user authentication and managing user IDs and roles.
The following are the supported authentication providers as described here.
Here are the command options for k2space.sh
:
These configuration files contain required or custom settings used by Fabric. Configure parameters as if you were editing any "ini" file to update config.ini
[section1]
key1=value1
key2=value2
[section2]
key1=value1
key2=value2
This temporary container sets the proper ownership of the persistent data's Space folder. After its execution, it should exit automatically.
K2view Fabric Web Studio's Docker Compose Runtime supports per-Space configuration overrides using custom .env
, compose.yaml
, and .config
files. When a new Fabric Space is created using the k2space.sh
script, the runtime checks for specially named files corresponding to the Space name and applies them accordingly.
When creating a Space named, for example, dcr210
, the following behavior applies:
.env
and .config
files are appended to the base configuration.compose.yaml
files are overridden completely if a matching file is found..env
Customization.env
file is always loaded first..env-dcr210
exists (where dcr210
is the Space name), its values will be appended to or override those defined in the base .env
.MAX_HEAP
, GIT_REPO
, or other custom variables..env
file's FABRIC_VERSION
parameter. Please contact your K2view representative if you'd like to use a later version of Fabric.compose.yaml
Customizationcompose.yaml
is loaded unless a file named compose-dcr210.yaml
exists.compose-dcr210.yaml
exists (where dcr210
is the Space name), it will completely replace the default compose.yaml
for that Space..config
Customizationcommon.config
file is always loaded.dcr210.config
exists (where dcr210
is the Space name), its values will be appended to or override settings from common.config
.You can also explicitly specify files when using the k2space.sh
script:
./k2space.sh create --env=custom.env --compose=custom-compose.yaml --config=custom.config dcr210
When using the --env
or --compose
options, automatic detection of .env-[spacename]
and compose-[spacename].yaml
is skipped.
For a Space named dcr210
, you might create:
.env-dcr210
to override heap size: MAX_HEAP=8G
compose-dcr210.yaml
to expose an additional port (e.g., JDBC port 5124):
```yaml ports:
- `dcr210.config` to point to a different System DB path or define SSO behavior:
ini [System] db.path=/custom/path/system.db ```
This flexible mechanism supports both shared and isolated runtime customization for Fabric Web Studio Spaces, making it ideal for multi-tenant development, QA, or demo environments.