Helm using the same template for python and java springboot



I would like to know can we use the same helm chart template for python and java sprinboot applications. I have my git repository name(sample) is common for these both the codes. But it uses different memory configs and envrionment variables. Please suggest me how can i deploy both the code using single helm chart template.