From 4c46fd6752651b1418b74e7258bfbabd2fed65e1 Mon Sep 17 00:00:00 2001 From: Pantelis Roditis Date: Thu, 17 Aug 2023 13:28:23 +0300 Subject: [PATCH 1/5] without these the build/feed fails --- ansible/Dockerfiles/example/variables.yml | 3 +++ ansible/Dockerfiles/sanitycheck/variables.yml | 3 +++ 2 files changed, 6 insertions(+) diff --git a/ansible/Dockerfiles/example/variables.yml b/ansible/Dockerfiles/example/variables.yml index ebc963ccf..6482ac785 100644 --- a/ansible/Dockerfiles/example/variables.yml +++ b/ansible/Dockerfiles/example/variables.yml @@ -1,6 +1,9 @@ --- hostname: example fqdn: example.echocity-f.com +ansible_host: 10.0.160.xx # The IP address for the target +DOCKER: localhost # Docker server to start the container +mac: de:ad:be:ef:c0:ff:ee # printf "02:42:%.2x:%.2x:%.2x:%.2x\n" 10 0 160 123 rootable: 1 # 0 for no difficulty: 3 # 0-6 player_spin: 1 # allow player spins diff --git a/ansible/Dockerfiles/sanitycheck/variables.yml b/ansible/Dockerfiles/sanitycheck/variables.yml index 907e972a9..9766edd51 100644 --- a/ansible/Dockerfiles/sanitycheck/variables.yml +++ b/ansible/Dockerfiles/sanitycheck/variables.yml @@ -1,6 +1,9 @@ --- hostname: sanitycheck fqdn: sanitycheck +ansible_host: 10.0.160.xx # The IP address for the target +DOCKER: localhost # Docker server to start the container +mac: de:ad:be:ef:c0:ff:ee # printf "02:42:%.2x:%.2x:%.2x:%.2x\n" 10 0 160 123 rootable: 0 difficulty: 0 timer: 0 From 874925ee65c9f7a2d49ce24108aa9bf029082630 Mon Sep 17 00:00:00 2001 From: Pantelis Roditis Date: Thu, 17 Aug 2023 13:28:45 +0300 Subject: [PATCH 2/5] mention the file for the group_vars --- docs/ansible/DOCKER-TARGETS.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/ansible/DOCKER-TARGETS.md b/docs/ansible/DOCKER-TARGETS.md index 9b4a489fc..6655d61fe 100644 --- a/docs/ansible/DOCKER-TARGETS.md +++ b/docs/ansible/DOCKER-TARGETS.md @@ -116,7 +116,7 @@ Feed the data to the backend ansible-playbook playbooks/feed-targets.yml -i inventories/targets -e '{"mui":{"URL": "http://127.0.0.1:8080"}}' ``` -You can also create a `group_vars` for the targets to include all those extra-vars details and not having to type them again +You can also create a file at `inventories/targets/group_vars/all.yml` for the targets to include all those extra-vars details and not having to type them again ```yaml DOCKER_REGISTRY: "myregistry:5000" DOCKER_REPOSITORY: "targets" @@ -146,4 +146,4 @@ This playbook provides a few tags to ease in managing single tasks, such as These tags can be used to perform a specific task or to skip some ie ```sh ansible-playbook playbooks/build-squash.yml -i inventories/targets --skip-tags push,rmi -``` \ No newline at end of file +``` From 50df1bdc8719d0f55f360e8c0eb2f1ef82e4e435 Mon Sep 17 00:00:00 2001 From: Pantelis Roditis Date: Thu, 17 Aug 2023 13:28:56 +0300 Subject: [PATCH 3/5] add missing instance_allowed flag --- ansible/playbooks/feed-targets.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ansible/playbooks/feed-targets.yml b/ansible/playbooks/feed-targets.yml index 42d8a90c1..728497b36 100644 --- a/ansible/playbooks/feed-targets.yml +++ b/ansible/playbooks/feed-targets.yml @@ -55,7 +55,8 @@ player_spin: "{{player_spin|default('1')}}" headshot_spin: "{{headshot_spin|default('1')}}" writeup_allowed: "{{writeup_allowed|default('1')}}" - description: '{{description}}' + instance_allowed: "{{instance_allowed|default('1')}}" + description: '{{description|default("")}}' ipoctet: '{{ansible_host}}' difficulty: "{{difficulty|default('0')}}" mac: '{{mac}}' @@ -116,7 +117,7 @@ # ignore_errors: true tags: - UI - when: target_id is defined and TargetOndemand is defined + when: target_id is defined and TargetOndemand is defined and ( TargetOndemand != 0 and TargetOndemand != false ) uri: url: "{{mui.URL}}/index.php?r=restapi/target-ondemand/create&access-token={{TOKEN}}" validate_certs: false From 7cdc5f1ea073b047452d0ec8550301540daed005 Mon Sep 17 00:00:00 2001 From: Pantelis Roditis Date: Thu, 17 Aug 2023 13:32:31 +0300 Subject: [PATCH 4/5] mention operating system for each option --- docs/DOCKER-REGISTRY.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/DOCKER-REGISTRY.md b/docs/DOCKER-REGISTRY.md index 89e1f51ec..0b657096f 100644 --- a/docs/DOCKER-REGISTRY.md +++ b/docs/DOCKER-REGISTRY.md @@ -6,7 +6,7 @@ There are many ways you can do that depending on your network topology and avail The following guide will provide instructions on running your own registry. -## On VPN gateway +## On VPN gateway (OpenBSD) The suggested way is to run the docker registry on its own system, however the next best thing as far as flexibility goes is to run it on your VPN gateway and limit access to the registry to `dockerd` servers. @@ -20,6 +20,7 @@ ansible-playbook --connection=local -i 127.0.0.1, runonce/docker-registry.yml ansible-playbook --connection=local -i 127.0.0.1, runonce/docker-registry.yml -e '@settings.yml' ``` +## On own server (OpenBSD) Alternatively, you can proceed with manual installation by following the steps. Install the needed packages From cda220bab1071bc090a25cbf25f2cc61b910b3b8 Mon Sep 17 00:00:00 2001 From: Pantelis Roditis Date: Thu, 17 Aug 2023 13:41:58 +0300 Subject: [PATCH 5/5] attempt to stick to the given version for now Yii2 has a bug on its latest release which causes typecasting operations on virtual columns to fail --- frontend/composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/composer.json b/frontend/composer.json index 6e173b13c..e19201da2 100644 --- a/frontend/composer.json +++ b/frontend/composer.json @@ -12,7 +12,7 @@ "minimum-stability": "stable", "require": { "php": ">=5.4.0 || >=8", - "yiisoft/yii2": "~2.0.45", + "yiisoft/yii2": "2.0.45", "yiisoft/yii2-bootstrap": "~2.0.0", "yiisoft/yii2-bootstrap4": "^2.0", "overals/yii2-whois": "~1.0.0",