Skip to content

Commit 3c71f04

Browse files
aptalcathelamer
authored andcommitted
Add optional hostname setting
1 parent 2a50f35 commit 3c71f04

2 files changed

Lines changed: 6 additions & 0 deletions

File tree

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ Here are some example snippets to help you get started creating a container.
6666
```
6767
docker create \
6868
--name=openssh-server \
69+
--hostname=openssh-server `#optional` \
6970
-e PUID=1000 \
7071
-e PGID=1000 \
7172
-e TZ=Europe/London \
@@ -94,6 +95,7 @@ services:
9495
openssh-server:
9596
image: linuxserver/openssh-server
9697
container_name: openssh-server
98+
hostname: openssh-server #optional
9799
environment:
98100
- PUID=1000
99101
- PGID=1000
@@ -118,6 +120,7 @@ Container images are configured using parameters passed at runtime (such as thos
118120

119121
| Parameter | Function |
120122
| :----: | --- |
123+
| `--hostname=openssh-server` | Optionally the hostname can be defined. |
121124
| `-p 2222` | ssh port |
122125
| `-e PUID=1000` | for UserID - see below for explanation |
123126
| `-e PGID=1000` | for GroupID - see below for explanation |

readme-vars.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ development_versions_items:
2525
# container parameters
2626
common_param_env_vars_enabled: true
2727
param_container_name: "{{ project_name }}"
28+
param_usage_include_hostname: 'optional' #you can set it to 'optional'
29+
param_hostname: "{{ project_name }}"
30+
param_hostname_desc: "Optionally the hostname can be defined."
2831
param_usage_include_vols: true
2932
param_volumes:
3033
- { vol_path: "/config", vol_host_path: "/path/to/appdata/config", desc: "Contains all relevant configuration files." }

0 commit comments

Comments
 (0)