2021-03-23 04:43:13 +00:00
|
|
|
|
|
|
|
from pathlib import Path
|
|
|
|
import os
|
|
|
|
import jinja2 as j2
|
|
|
|
|
|
|
|
TEMPLATE_FILE = 'bitbucket-pipelines.yml.j2'
|
2024-02-12 01:14:18 +00:00
|
|
|
REPOS = ['atlassian/confluence']
|
2021-03-23 04:43:13 +00:00
|
|
|
|
|
|
|
images = {
|
2021-07-14 23:14:53 +00:00
|
|
|
'Confluence': {
|
2024-04-15 06:21:56 +00:00
|
|
|
"11-default": {
|
2024-01-23 03:25:13 +00:00
|
|
|
'start_version': '7.19',
|
2024-04-15 06:21:56 +00:00
|
|
|
'end_version': '8.3',
|
2021-03-23 04:43:13 +00:00
|
|
|
'default_release': True,
|
2024-05-21 00:34:40 +00:00
|
|
|
'default_eap': False,
|
2024-07-30 07:50:38 +00:00
|
|
|
'base_image': 'eclipse-temurin:11-noble',
|
2022-06-21 12:19:12 +00:00
|
|
|
'tag_suffixes': ['jdk11','ubuntu-jdk11'],
|
2021-03-23 04:43:13 +00:00
|
|
|
'dockerfile': 'Dockerfile',
|
|
|
|
'docker_repos': REPOS,
|
2022-08-07 10:56:40 +00:00
|
|
|
},
|
2024-04-15 06:21:56 +00:00
|
|
|
11: {
|
|
|
|
'start_version': '8.3',
|
|
|
|
'end_version': '9.0',
|
|
|
|
'default_release': False,
|
2024-05-21 00:34:40 +00:00
|
|
|
'default_eap': False,
|
2024-07-30 07:50:38 +00:00
|
|
|
'base_image': 'eclipse-temurin:11-noble',
|
2024-04-15 06:21:56 +00:00
|
|
|
'tag_suffixes': ['jdk11','ubuntu-jdk11'],
|
|
|
|
'dockerfile': 'Dockerfile',
|
|
|
|
'docker_repos': REPOS,
|
|
|
|
},
|
2022-08-07 10:56:40 +00:00
|
|
|
17: {
|
2024-02-12 01:14:18 +00:00
|
|
|
'start_version': '8.0',
|
2024-04-15 06:21:56 +00:00
|
|
|
'end_version': '8.3',
|
|
|
|
'default_release': False,
|
2024-05-21 00:34:40 +00:00
|
|
|
'default_eap': True,
|
2024-07-30 07:50:38 +00:00
|
|
|
'base_image': 'eclipse-temurin:17-noble',
|
2024-04-15 06:21:56 +00:00
|
|
|
'tag_suffixes': ['jdk17','ubuntu-jdk17'],
|
|
|
|
'dockerfile': 'Dockerfile',
|
|
|
|
'docker_repos': REPOS,
|
|
|
|
},
|
|
|
|
"17-default": {
|
|
|
|
'start_version': '8.3',
|
2024-02-12 01:14:18 +00:00
|
|
|
'default_release': True,
|
2024-05-21 00:34:40 +00:00
|
|
|
'default_eap': True,
|
2024-07-30 07:50:38 +00:00
|
|
|
'base_image': 'eclipse-temurin:17-noble',
|
2022-08-07 10:56:40 +00:00
|
|
|
'tag_suffixes': ['jdk17','ubuntu-jdk17'],
|
|
|
|
'dockerfile': 'Dockerfile',
|
|
|
|
'docker_repos': REPOS,
|
2024-03-13 04:08:20 +00:00
|
|
|
},
|
|
|
|
"17-ubi": {
|
|
|
|
'start_version': '8.5.6',
|
2024-04-15 06:21:56 +00:00
|
|
|
'default_release': False,
|
2024-03-13 04:08:20 +00:00
|
|
|
'base_image': 'registry.access.redhat.com/ubi9/openjdk-17',
|
|
|
|
'tag_suffixes': ['ubi9','ubi9-jdk17'],
|
|
|
|
'dockerfile': 'Dockerfile.ubi',
|
|
|
|
'docker_repos': REPOS,
|
2024-07-31 01:27:07 +00:00
|
|
|
'snyk_threshold': 'critical'
|
2021-03-23 04:43:13 +00:00
|
|
|
}
|
|
|
|
},
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
def main():
|
|
|
|
jenv = j2.Environment(
|
|
|
|
loader=j2.FileSystemLoader('.'),
|
|
|
|
lstrip_blocks=True,
|
|
|
|
trim_blocks=True)
|
|
|
|
template = jenv.get_template(TEMPLATE_FILE)
|
2022-03-16 03:41:23 +00:00
|
|
|
generated_output = template.render(images=images, batches=8)
|
2021-03-23 04:43:13 +00:00
|
|
|
|
|
|
|
print(generated_output)
|
|
|
|
|
|
|
|
if __name__ == '__main__':
|
|
|
|
main()
|