sealer
sealer copied to clipboard
[Proposal] separate env render function with two different instructions
Issue Description
Currently , we use env
at Clusterfile to render both basefs files and the environment variables for the shell to run scripts which bring more complexity and more difficult to understand for end user. Introduction form the official website : https://github.com/sealerio/sealer.cool/blob/main/src/docs/getting-started/using-clusterfile.md#env-render-support
And if the user has multiple fields that need to be modified at the same time, there will be potential problems using just one key from env render setting.
Therefore, I thought we can separate two functions with two Clusterfile instruction. one is setting the environment variables for the shell to run. One is used for rendering basefs .tmpl files.
Type: feature request
Describe what feature you want
Additional context
Add any other context or screenshots about the feature request here.
i thought , for rendering basefs .tmpl files: We can migrate it to the config module.
if the path is existed, use render
, if not use dump
.
apiVersion: sealer.aliyun.com/v1alpha1
kind: Config
metadata:
name: kubeadm-config
spec:
path: etc/kubeadm.yml
data: |
PodSubnet: 100.64.0.0/10
ServiceSubnet: 10.96.0.0/22
There are too many stuff should be provided by users, it obviously will make it complicated for users. And I agree it will reduce the rate of failure.
I think env
is a very obvious word which is reserved in programmers' world. So, only user env
word in runtime environment value setting. Please do not use env
word in rendering ever.
Maybe we could consider use --render-data
to represent the rendering data which has a format of key=value
.
@kakaZhou719 @justadogistaken