All Downloads are FREE. Search and download functionalities are using the official Maven repository.

templates.integration-test.it.tiltfile.vm Maven / Gradle / Ivy

config.define_string("aissembleVersion")
config.define_string_list("to-run", args=True)
cfg = config.parse()

build_args = { 'DOCKER_BASELINE_REPO_ID': 'ghcr.io/',
               'VERSION_AISSEMBLE': cfg.get('aissembleVersion', '') }

allow_k8s_contexts('local')
docker_prune_settings(num_builds=1, keep_recent=1)

groups = {
    'pipeline': ['spark-operator', 'spark-infrastructure', 'hive-metastore-db', 'kafka-cluster',
    'policy-decision-point']
}
resources = []
for arg in cfg.get('to-run', []):
    if arg in groups:
        resources += groups[arg]
    else:
        # also support specifying individual services instead of groups, e.g. `tilt up a b d`
        resources.append(arg)
config.set_enabled_resources(resources)

parent_dir = '../../../../../'

#set ($index = $artifactId.indexOf('-tests'))
#set ($parentArtifactId = $artifactId.substring(0, $index))

# Spark
yaml = helm(
parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/spark-infrastructure',
values=[parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/spark-infrastructure/values.yaml',
parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/spark-infrastructure/values-dev.yaml']
)
k8s_yaml(yaml)

yaml = helm(
parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/spark-operator',
values=[parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/spark-operator/values.yaml',
parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/spark-operator/values-dev.yaml']
)
k8s_yaml(yaml)

# Kafka
yaml = helm(
    parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/kafka-cluster',
    values=[parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/kafka-cluster/values.yaml',
    parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/kafka-cluster/values-dev.yaml']
)
k8s_yaml(yaml)

# Policy Decision Point
docker_build(
    ref='${parentArtifactId}-policy-decision-point-docker',
    context=parent_dir + '${parentArtifactId}-docker/${parentArtifactId}-policy-decision-point-docker',
    build_args=build_args,
    dockerfile=parent_dir + '${parentArtifactId}-docker/${parentArtifactId}-policy-decision-point-docker/src/main/resources/docker/Dockerfile'
)

yaml = helm(
    parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/policy-decision-point',
    values=[parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/policy-decision-point/values.yaml',
    parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/policy-decision-point/values-dev.yaml']
)
k8s_yaml(yaml)

# S3 Local
yaml = helm(
    parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/s3-local',
    values=[parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/s3-local/values.yaml',
    parent_dir + '${parentArtifactId}-deploy/src/main/resources/apps/s3-local/values-dev.yaml']
)
k8s_yaml(yaml)




© 2015 - 2025 Weber Informatics LLC | Privacy Policy