Export hostname via __target_host_name #292
Labels
No labels
bugfix
cleanup
discussion
documentation
doing
done
feature
improvement
packaging
Stale
testing
TODO
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: ungleich-public/cdist#292
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Created by: telmich
The __target_host variable contains whatever a user specified.
To allow the user to rely on a variable that contains the hostname (without domain), the variable __target_host_name should be exported, with only containing everything until excluding the first dot.
Domain handling can be done by the user better than from the cdist core, for instance by adding conf/manifest/domain which contains
Created by: telmich
I think we do not need to fix this anymore - shell can handle this easily.
Created by: telmich
good point. maybe we need to check if it is an IPv4 address and if so, keep it as it is
Created by: jdguffey
What if a user provides an IP address rather than a hostname?
On Nov 14, 2012, at 10:22 AM, Nico Schottelius notifications@github.com wrote:
Created by: telmich
Good comment from sar:
16:13 < sar> telmich: echo "${__target_host%%.*}", problem solved