diff --git a/basis/bin/auto_env.sh b/basis/bin/auto_env.sh index 53202266..43d56c31 100755 --- a/basis/bin/auto_env.sh +++ b/basis/bin/auto_env.sh @@ -7,7 +7,7 @@ if [ "$TF_VAR_instance_shape" == "VM.Standard.A1.Flex" ]; then if [ "$TF_VAR_deploy_type" == "kubernetes" ] || [ "$TF_VAR_deploy_type" == "container_instance" ] || [ "$TF_VAR_deploy_type" == "function" ]; then MISMATCH_PLATFORM="ERROR: ARM (Ampere) build using Containers (Kubernetes / Cointainer Instance / Function) needs to run on ARM processor" DESIRED_PLATFORM="ARM (aarch64)" - fi + fi fi elif [ `arch` != "x86_64" ]; then if [ "$TF_VAR_deploy_type" == "kubernetes" ] || [ "$TF_VAR_deploy_type" == "container_instance" ] || [ "$TF_VAR_deploy_type" == "function" ]; then @@ -61,6 +61,9 @@ if [ "$1" == "-no-auto" ]; then return fi +# Change the prompt +export PS1="[\e[0;3m\${TF_VAR_prefix}\e(B\e[m \u@\h \W]$ " + # Silent mode (default is not silent) if [ "$1" == "-silent" ]; then SILENT_MODE=true diff --git a/basis/bin/shared_bash_function.sh b/basis/bin/shared_bash_function.sh index 7156bbe8..8300d25c 100755 --- a/basis/bin/shared_bash_function.sh +++ b/basis/bin/shared_bash_function.sh @@ -273,7 +273,7 @@ get_ui_url() { elif [ "$TF_VAR_deploy_type" == "kubernetes" ]; then export TF_VAR_ingress_ip=`kubectl get service -n ingress-nginx ingress-nginx-controller -o jsonpath="{.status.loadBalancer.ingress[0].ip}"` export UI_URL=http://${TF_VAR_ingress_ip}/${TF_VAR_prefix} - if [ "$TF_VAR_tls" != "" ] && [ "$TF_VAR_certificate_ocid" != "" ]; then + if [ "$TF_VAR_tls" != "" ] && [ "$TF_VAR_dns_name" != "" ]; then export UI_HTTP=$UI_URL export UI_URL=https://${TF_VAR_dns_name}/${TF_VAR_prefix} fi @@ -510,6 +510,13 @@ certificate_dir_before_terraform() { echo "ERROR: compute: certificate_dir_before_terraform: missing variables TF_VAR_certificate_dir" exit 1 fi + elif [ "$TF_VAR_deploy_type" == "kubernetes" ]; then + if [ "$TF_VAR_tls" == "new_http_01" ]; then + echo "New Certificate will be created after the deployment." + else + echo "ERROR: kubernetes: certificate_dir_before_terraform: missing variables TF_VAR_certificate_dir" + exit 1 + fi elif [ "$TF_VAR_certificate_ocid" == "" ] && [ "$TF_VAR_certificate_dir" != "" ] ; then certificate_create elif [ "$TF_VAR_certificate_ocid" != "" ]; then diff --git a/basis/bin/shared_infra_as_code.sh b/basis/bin/shared_infra_as_code.sh index c2d347de..11adda52 100755 --- a/basis/bin/shared_infra_as_code.sh +++ b/basis/bin/shared_infra_as_code.sh @@ -56,9 +56,9 @@ resource_manager_create_or_update() { VAR_FILE_PATH=$TARGET_DIR/resource_manager_variables.json if [ -f $TARGET_DIR/resource_manager_stackid ]; then echo "Stack exists already ( file target/resource_manager_stackid found )" - BACKUP_POSTFIX=`date '+%Y%m%d-%H%M%S'` - mv $ZIP_FILE_PATH $ZIP_FILE_PATH.$BACKUP_POSTFIX - mv $VAR_FILE_PATH $VAR_FILE_PATH.$BACKUP_POSTFIX + DATE_POSTFIX=`date '+%Y%m%d-%H%M%S'` + mv $ZIP_FILE_PATH $ZIP_FILE_PATH.$DATE_POSTFIX + mv $VAR_FILE_PATH $VAR_FILE_PATH.$DATE_POSTFIX fi if [ -f $ZIP_FILE_PATH ]; then @@ -77,9 +77,9 @@ resource_manager_create_or_update() { cat $TARGET_DIR/tf_var.sh | sed "s/export TF_VAR_/\"/g" | sed "s/=\"/\": \"/g" | sed ':a;N;$!ba;s/\"\n/\", /g' | sed ':a;N;$!ba;s/\n/\\n/g' | sed 's/$/}/'>> $VAR_FILE_PATH if [ -f $TARGET_DIR/resource_manager_stackid ]; then - if cmp -s $ZIP_FILE_PATH $ZIP_FILE_PATH.$BACKUP_POSTFIX; then + if cmp -s $ZIP_FILE_PATH $ZIP_FILE_PATH.$DATE_POSTFIX; then rs_echo "Zip files are identical" - if cmp -s $VAR_FILE_PATH $VAR_FILE_PATH.$BACKUP_POSTFIX; then + if cmp -s $VAR_FILE_PATH $VAR_FILE_PATH.$DATE_POSTFIX; then rs_echo "Var files are identical" exit else diff --git a/basis/starter.sh b/basis/starter.sh index 6f2a13c7..7856b0ee 100755 --- a/basis/starter.sh +++ b/basis/starter.sh @@ -9,43 +9,56 @@ export ARG2=$2 export ARG3=$3 if [ -z $ARG1 ] || [ "$ARG1" == "help" ]; then - echo "Help:" + echo "--- HELP -------------------------------------------------------------------------------------" + echo "https://www.ocistarter.com/" + echo "https://www.ocistarter.com/help (tutorial + how to customize)" echo - echo "--- BUILD -------------------------------------------------------------------------" - echo "./starter.sh build - Build all" - echo "./starter.sh build app - Build the application" - echo "./starter.sh build ui - Build the user interface" + echo "--- BUILD ------------------------------------------------------------------------------------" + echo "./starter.sh build - Build and deploy" + echo "./starter.sh build app - Build the application (APP)" + echo "./starter.sh build ui - Build the user interface (UI)" echo - echo "--- DESTROY -----------------------------------------------------------------------" + echo "--- DESTROY ----------------------------------------------------------------------------------" echo "./starter.sh destroy - Destroy all" echo - echo "--- SSH ---------------------------------------------------------------------------" - echo "./starter.sh ssh compute - SSH to compute (Compute mode)" + echo "--- SSH --------------------------------------------------------------------------------------" + echo "./starter.sh ssh compute - SSH to compute (Deployment: Compute)" echo "./starter.sh ssh bastion - SSH to bastion" - echo "./starter.sh ssh db_node - SSH to DB_NODE (OCI Oracle Base DB)" + echo "./starter.sh ssh db_node - SSH to DB_NODE (Database: Oracle DB)" echo - echo "--- TERRAFORM (or RESOURCE MANAGER ) ----------------------------------------------" + echo "--- TERRAFORM (or RESOURCE MANAGER ) ---------------------------------------------------------" echo "./starter.sh terraform plan - Plan" echo "./starter.sh terraform apply - Apply" echo "./starter.sh terraform destroy - Destroy" echo - echo "--- GENERATE ----------------------------------------------------------------------" + echo "--- GENERATE ---------------------------------------------------------------------------------" echo "./starter.sh generate auth_token - Create OCI Auth Token (ex: docker login)" echo - echo "--- DEPLOY ------------------------------------------------------------------------" + echo "--- DEPLOY -----------------------------------------------------------------------------------" echo "./starter.sh deploy bastion - Deploy the bastion (+create DB tables)" - echo "./starter.sh deploy compute - Deploy APP and UI on Compute (Compute mode)" - echo "./starter.sh deploy oke - Deploy APP and UI on OKE (OKE mode)" + echo "./starter.sh deploy compute - Deploy APP and UI on Compute (Deployment: Compute)" + echo "./starter.sh deploy oke - Deploy APP and UI on OKE (Deployment: Kubernetes)" echo - echo "--- KUBECTL -----------------------------------------------------------------------" - echo ". ./env.sh - Set kubeconfig to connect to Kubernetes" + echo "--- KUBECTL ----------------------------------------------------------------------------------" + echo "./starter.sh env - Set kubeconfig to connect to Kubernetes" echo "kubectl get pods - Example of a command to check the PODs" + echo exit fi if [ "$ARG1" == "build" ]; then - # Show the log and save it in target/build.log - bin/build_all.sh ${@:2} 2>&1 | tee $TARGET_DIR/build.log + if [ "$ARG2" == "" ]; then + # Show the log and save it in target/build.log + bin/build_all.sh ${@:2} 2>&1 | tee $TARGET_DIR/build.log + elif [ "$ARG2" == "app" ]; then + src/app/build_app.sh ${@:2} + elif [ "$ARG2" == "ui" ]; then + src/ui/build_ui.sh ${@:2} + else + echo "Unknow command: $ARG1 $ARG2" + fi + + elif [ "$ARG1" == "destroy" ]; then bin/destroy_all.sh ${@:2} 2>&1 | tee $TARGET_DIR/destroy.log elif [ "$ARG1" == "ssh" ]; then @@ -60,11 +73,11 @@ elif [ "$ARG1" == "ssh" ]; then fi elif [ "$ARG1" == "terraform" ]; then if [ "$ARG2" == "plan" ]; then - src/terraform/plan.sh $ARG3 + src/terraform/plan.sh ${@:2} elif [ "$ARG2" == "apply" ]; then - src/terraform/apply.sh $ARG3 + src/terraform/apply.sh ${@:2} elif [ "$ARG2" == "destroy" ]; then - src/terraform/destroy.sh $ARG3 + src/terraform/destroy.sh ${@:2} else echo "Unknow command: $ARG1 $ARG2" fi @@ -85,6 +98,8 @@ elif [ "$ARG1" == "deploy" ]; then echo "Unknow command: $ARG1 $ARG2" exit 1 fi +elif [ "$ARG1" == "env" ]; then + bash --rcfile ./env.sh else echo "Unknow command: $ARG1" exit 1 diff --git a/option/oke/oke_destroy.sh b/option/oke/oke_destroy.sh index e82e0aa4..2a274afe 100755 --- a/option/oke/oke_destroy.sh +++ b/option/oke/oke_destroy.sh @@ -37,4 +37,5 @@ helm uninstall ingress-nginx --namespace ingress-nginx # kubectl delete -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/controller-v1.4.0/deploy/static/provider/cloud/deploy.yaml # Rename kubeconfig. Avoid to reuse if a new OKE is created for the same directory. -mv kubeconfig_starter kubeconfig_starter.destroyed \ No newline at end of file +DATE_POSTFIX=`date '+%Y%m%d-%H%M%S'` +mv $KUBECONFIG $KUBECONFIG.${DATE_POSTFIX} \ No newline at end of file diff --git a/option/src/app/dotnet/src/Controllers/DeptController.j2.cs b/option/src/app/dotnet/src/Controllers/DeptController.j2.cs index c2f0cff8..9143ada5 100644 --- a/option/src/app/dotnet/src/Controllers/DeptController.j2.cs +++ b/option/src/app/dotnet/src/Controllers/DeptController.j2.cs @@ -19,7 +19,11 @@ public DeptController(ILogger logger) } [Route("dept")] + {%- if db_family == "nosql" %} + public async Task> Get() + {%- else %} public IEnumerable Get() + {%- endif %} { {{ m.dept() }} return a.ToArray(); diff --git a/option/src/app/java_helidon/microprofile-config.properties.j2.tmpl b/option/src/app/java_helidon/microprofile-config.properties.j2.tmpl index f1daa98e..0ee8716f 100644 --- a/option/src/app/java_helidon/microprofile-config.properties.j2.tmpl +++ b/option/src/app/java_helidon/microprofile-config.properties.j2.tmpl @@ -5,9 +5,6 @@ server.host=0.0.0.0 # Change the following to true to enable the optional MicroProfile Metrics REST.request metrics metrics.rest-request.enabled=false -# Application properties. This is the default greeting -app.greeting=Hello - # Datasource properties {%- if db_family != "none" %} {%- if db_family == "oracle" %} @@ -17,15 +14,11 @@ javax.sql.DataSource.ds1.dataSourceClassName=com.mysql.cj.jdbc.MysqlDataSource {%- elif db_family == "psql" %} javax.sql.DataSource.ds1.dataSourceClassName=org.postgresql.ds.PGSimpleDataSource {%- endif %} -javax.sql.DataSource.ds1.dataSource.url=##JDBC_URL## -javax.sql.DataSource.ds1.dataSource.user=##DB_USER## -javax.sql.DataSource.ds1.dataSource.password=##DB_PASSWORD## -{%- endif %} {%- if db_family == "nosql" %} # Oracle NoSQL Connection -jnosql.keyvalue.database=dept -jnosql.document.database=dept +jnosql.keyvalue.database=deptjee +jnosql.document.database=deptjee jnosql.oracle.nosql.table.read.limit=10 jnosql.oracle.nosql.table.write.limit=10 jnosql.oracle.nosql.table.storage.gb=1 @@ -35,5 +28,11 @@ jnosql.oracle.nosql.compartment=${TF_VAR_compartment_ocid} jnosql.oracle.nosql.deployment=CLOUD_INSTANCE_PRINCIPAL {%- else %} jnosql.oracle.nosql.deployment=CLOUD_RESOURCE_PRINCIPAL -{%- endif %} {%- endif %} +{%- else %} +javax.sql.DataSource.ds1.dataSource.url=##JDBC_URL## +javax.sql.DataSource.ds1.dataSource.user=##DB_USER## +javax.sql.DataSource.ds1.dataSource.password=##DB_PASSWORD## +{%- endif %} +{%- endif %} + diff --git a/option/src/app/java_helidon/pom.j2.xml b/option/src/app/java_helidon/pom.j2.xml index 8ce0fc25..f8fea049 100644 --- a/option/src/app/java_helidon/pom.j2.xml +++ b/option/src/app/java_helidon/pom.j2.xml @@ -6,7 +6,7 @@ io.helidon.applications helidon-mp - 3.1.0 + 3.2.6 me.opc-helidon diff --git a/option/src/app/java_helidon/src/main/java/me/opc/mp/database/package-info.java b/option/src/app/java_helidon/src/main/java/me/opc/mp/database/package-info.java deleted file mode 100644 index 2706152c..00000000 --- a/option/src/app/java_helidon/src/main/java/me/opc/mp/database/package-info.java +++ /dev/null @@ -1,2 +0,0 @@ - -package me.opc.mp.database; diff --git a/option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/DeptResource.j2.java b/option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/DeptResource.j2.java deleted file mode 100644 index e17afbba..00000000 --- a/option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/DeptResource.j2.java +++ /dev/null @@ -1,31 +0,0 @@ -{% import "java.j2_macro" as m with context %} -package me.opc.mp.database; - -import jakarta.persistence.*; -import jakarta.ws.rs.*; -import jakarta.ws.rs.core.MediaType; -import jakarta.inject.*; -{{ m.import() }} - -/** - * Dept Table - */ -@Path("/") -public class DeptResource { - @Inject - private DeptRepository deptRepository; - - @GET - @Path("dept") - @Produces(MediaType.APPLICATION_JSON) - public List getDept() throws Exception { - return deptRepository.findAll().toList(); - } - - @GET - @Path("info") - @Produces(MediaType.TEXT_PLAIN) - public String getInfo() { - return "Java - Helidon - {{ dbName }}"; - } -} diff --git a/option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/FieldAccessStrategy.java b/option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/FieldAccessStrategy.java deleted file mode 100644 index c0d3ff33..00000000 --- a/option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/FieldAccessStrategy.java +++ /dev/null @@ -1,18 +0,0 @@ -package me.opc.mp.database; - -import jakarta.json.bind.config.PropertyVisibilityStrategy; - -import java.lang.reflect.Field; -import java.lang.reflect.Method; - -public class FieldAccessStrategy implements PropertyVisibilityStrategy { - @Override - public boolean isVisible(Field field) { - return true; - } - - @Override - public boolean isVisible(Method method) { - return true; - } -} \ No newline at end of file diff --git a/option/src/app/java_helidon4_nosql/src/main/resources/application.yaml b/option/src/app/java_helidon4_nosql/src/main/resources/application.yaml deleted file mode 100644 index 5852e277..00000000 --- a/option/src/app/java_helidon4_nosql/src/main/resources/application.yaml +++ /dev/null @@ -1,9 +0,0 @@ -# Oracle NoSQL Configuration -jnosql: - keyvalue: - database: beers - document: - database: beers - oracle: - nosql: - host: http://localhost:8080 \ No newline at end of file diff --git a/option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/Dept.java b/option/src/app/java_helidon_nosql/src/main/java/me/opc/mp/database/Dept.java similarity index 55% rename from option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/Dept.java rename to option/src/app/java_helidon_nosql/src/main/java/me/opc/mp/database/Dept.java index 973a5450..06e60cd6 100644 --- a/option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/Dept.java +++ b/option/src/app/java_helidon_nosql/src/main/java/me/opc/mp/database/Dept.java @@ -5,11 +5,7 @@ @Entity @JsonbVisibility(FieldAccessStrategy.class) -public class Dept { - @Id - private int deptno; - @Column - private String dname; - @Column - private String loc; +public record Dept (@Id int deptno, + @Column String dname, + @Column String loc) { } \ No newline at end of file diff --git a/option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/DeptRepository.java b/option/src/app/java_helidon_nosql/src/main/java/me/opc/mp/database/DeptRepository.java similarity index 100% rename from option/src/app/java_helidon4_nosql/src/main/java/me/opc/mp/database/DeptRepository.java rename to option/src/app/java_helidon_nosql/src/main/java/me/opc/mp/database/DeptRepository.java diff --git a/option/src/app/java_helidon_nosql/src/main/java/me/opc/mp/database/DeptResource.j2.java b/option/src/app/java_helidon_nosql/src/main/java/me/opc/mp/database/DeptResource.j2.java new file mode 100644 index 00000000..13721d99 --- /dev/null +++ b/option/src/app/java_helidon_nosql/src/main/java/me/opc/mp/database/DeptResource.j2.java @@ -0,0 +1,45 @@ +{% import "java.j2_macro" as m with context %} +package me.opc.mp.database; + +import jakarta.persistence.*; +import jakarta.ws.rs.*; +import jakarta.ws.rs.core.MediaType; +import jakarta.inject.*; +import jakarta.annotation.*; +{{ m.import() }} + +/** + * Dept Table + */ +@Path("/") +public class DeptResource { + @Inject + private DeptRepository repository; + + @PostConstruct + private void init() { + try { + System.out.println("Insert row " + repository.save(new Dept(10, "ACCOUNTING", "BRUSSELS"))); + System.out.println("Insert row " + repository.save(new Dept(20, "RESEARCH", "JAKARTA NOSQL"))); + System.out.println("Insert row " + repository.save(new Dept(30, "SALES", "ROME"))); + System.out.println("Insert row " + repository.save(new Dept(40, "OPERATIONS", "MADRID"))); + } catch (Exception e ) { + System.err.println("Init Exception:" + e.getMessage()); + e.printStackTrace(); + } + } + + @GET + @Path("dept") + @Produces(MediaType.APPLICATION_JSON) + public List getDept() throws Exception { + return repository.findAll().toList(); + } + + @GET + @Path("info") + @Produces(MediaType.TEXT_PLAIN) + public String getInfo() { + return "Java - Helidon - {{ dbName }}"; + } +} diff --git a/option/src/app/java_springboot_rac/src/main/java/com/example/demo/RacController.java b/option/src/app/java_springboot_rac/src/main/java/com/example/demo/RacController.java index 535ed831..ed013764 100644 --- a/option/src/app/java_springboot_rac/src/main/java/com/example/demo/RacController.java +++ b/option/src/app/java_springboot_rac/src/main/java/com/example/demo/RacController.java @@ -40,7 +40,7 @@ public void run() { } @Autowired - public RacController(DbProperties aProperties) throws SQLException { + public RacController() throws SQLException { resetConnectionPool("jtac"); } diff --git a/option/src/j2_macro/dotnet.j2_macro b/option/src/j2_macro/dotnet.j2_macro index e40b14d5..aa9f54d5 100644 --- a/option/src/j2_macro/dotnet.j2_macro +++ b/option/src/j2_macro/dotnet.j2_macro @@ -96,29 +96,13 @@ using Oracle.NoSQL.SDK; } {%- elif db_family == "nosql" %} List a = new List(); - /* - var client = new NoSQLClient( new NoSQLConfig{ - Endpoint=Environment.GetEnvironmentVariable("TF_VAR_nosql_endpoint"), - Compartment=Environment.GetEnvironmentVariable("TF_VAR_compartment_ocid"), - {%- if deploy_type in ["compute", "kubernetes", "instance_pool"] %} - AuthorizationProvider=IAMAuthorizationProvider.CreateWithInstancePrincipal() - {%- else %} - AuthorizationProvider=IAMAuthorizationProvider.CreateWithResourcePrincipal() - {%- endif %} - }); - */ try { - var options = new QueryOptions(); - do { - var task = Task.Run(() => client.QueryAsync("select deptno, dname, loc from dept", options)); - task.Wait(); - var result = task.Result; + await foreach(var result in client.GetQueryAsyncEnumerable("select deptno, dname, loc from dept")) + { foreach(var row in result.Rows) { a.Add( new Dept{ deptno = row.GetValueAtIndex(0).AsInt32.ToString(), dname = row.GetValueAtIndex(1).AsString, loc = row.GetValueAtIndex(2).AsString } ); } - options.ContinuationKey = result.ContinuationKey; } - while(options.ContinuationKey != null); } catch(Exception ex) { Console.WriteLine(ex.Message); diff --git a/option/src/j2_macro/java.j2_macro b/option/src/j2_macro/java.j2_macro index 18d07823..d33c49a8 100644 --- a/option/src/j2_macro/java.j2_macro +++ b/option/src/j2_macro/java.j2_macro @@ -28,6 +28,20 @@ import javax.json.*; com.oracle.nosql.sdk spring-data-oracle-nosql 2.0.0 + + {%- elif java_framework == "helidon" %} + + io.helidon.microprofile.openapi + helidon-microprofile-openapi + + + jakarta.json.bind + jakarta.json.bind-api + + + org.eclipse.jnosql.databases + jnosql-oracle-nosql + 1.1.0 {%- endif %} {%- elif db_family_type == "sql" %} diff --git a/option/src/j2_macro/node.j2_macro b/option/src/j2_macro/node.j2_macro index bec61e0e..be39a4c9 100644 --- a/option/src/j2_macro/node.j2_macro +++ b/option/src/j2_macro/node.j2_macro @@ -120,16 +120,11 @@ function createClient() { {%- endmacro -%} {% macro nosql() -%} + // See https://oracle.github.io/nosql-node-sdk/pages/tables.html let rows = []; - const opt = {}; - do { - const result = await client.query('SELECT deptno, dname, loc FROM dept', opt); + for await(let result of client.queryIterable('SELECT deptno, dname, loc FROM dept')) { for(let row of result.rows) { rows.push( row ); - } - opt.continuationKey = result.continuationKey; - } while(opt.continuationKey); - + } + } {%- endmacro -%} - - diff --git a/test_suite/test_suite_shared.sh b/test_suite/test_suite_shared.sh index 69b796f9..fc8734ea 100755 --- a/test_suite/test_suite_shared.sh +++ b/test_suite/test_suite_shared.sh @@ -15,6 +15,7 @@ OPTION_SHAPE=amd OPTION_INFRA_AS_CODE=terraform_local OPTION_JAVA_FRAMEWORK=springboot OPTION_JAVA_VM=jdk +OPTION_TSONE_ID=0 # No color for terraforms logs export nocolorarg=1 @@ -164,6 +165,8 @@ build_option() { NAME=${NAME}-rm fi NAME=${NAME/_/-} + NAME=${NAME/_/-} + NAME=${NAME/_/-} start_test $NAME if [ "$TEST_ERROR_ONLY" != "" ]; then if grep -q "$TEST_DIR" $TEST_HOME/error_rerun.sh; then @@ -206,8 +209,10 @@ build_option() { -bastion_ocid $TF_VAR_bastion_ocid \ -fnapp_ocid $TF_VAR_fnapp_ocid > ${TEST_DIR}.log 2>&1 else + # Unique name to allow more generations of TLS certificates. The prefix is used as hostname for TLS http_01. + OPTION_TSONE_ID=$((OPTION_TSONEID+1)) ./oci_starter.sh \ - -prefix tsone \ + -prefix tsone${OPTION_TSONE_ID} \ -deploy $OPTION_DEPLOY \ -ui $OPTION_UI \ -language $OPTION_LANG \