commit - da1080d4c8de7b5e2e41a156742743e6b2a9a2af
commit + 6be5987f8d4bc64ec4365305df21903a04fc3689
blob - e9a15d1d6f5fd8030f1b1ebc35eb1b9c8fc151e7
blob + b89e9639156b5dfe71e8cc2e2b2a7a1f407b2fa0
--- deploy.pl
+++ deploy.pl
chomp($jot_pass);
my $_ipv4 = $vms{$vm_name}{'ipv4'} || "autoconf";
$_ipv4 = "autoconf" if $conf{'conf'}{'DHCPD'} eq "yes";
+
+ #my $_dhcp_ipv4 = $conf{'conf'}{'IP_PREFIX'} . "." . ($conf{'conf'}{'IP_START'} + $vms{$vm_name}{'vm_number'}) if ;
+
my $_ipv4_gateway = $vms{$vm_name}{'ipv4_gw'} || $conf{'conf'}{'ROUTER'};
my $_ipv6 = $vms{$vm_name}{'ipv6'} || $conf{'conf'}{'IPV6_PREFIX'} . ":" . ($conf{'conf'}{'IPV6_START'} + $vms{$vm_name}{'vm_number'}) . "::" . ($conf{'conf'}{'IP_START'} + $vms{$vm_name}{'vm_number'});
my $_ipv6_gateway = $vms{$vm_name}{'ipv6_gw'} || $conf{'conf'}{'IPV6_PREFIX'} . ":" . ($conf{'conf'}{'IPV6_START'} + $vms{$vm_name}{'vm_number'}) . "::1";
blob - a885fda7a6a883a98aef558da195401ebcedfa9c
blob + c005a38e7a8aeaaf535f92f2dbab5e93c02ea861
--- notify.pl
+++ notify.pl
# 2021/05/09 complete restructure and KISS
# 2022/11/13 added price structure for notifications
# 2023/05/05 variable clean up, rework IP logic
+# 2023/12/03 price increase, +3
#
use 5.024;
use strict;
my $message = $ARGV[2] || "empty";
# define the prices for the different components of the VM
-my $base_price = '64';
+my $base_price = '67';
my %memory_prices = ('2G' => '10', '4G' => '30', '8G' => '70');
my %hdd_prices = ('50G' => '50', '100G' => '100', '150G' => '150', '200G' => '200');
my $ideal_url;
my %stripe_urls = (
'sponsor' => 'SPONSORED',
'sponsored' => 'SPONSORED',
- '44' => 'https://buy.stripe.com/28odR0aWK0jq0aAeV0',
- '64' => 'https://buy.stripe.com/8wMaEO0i67LS1eE288',
- '74' => 'https://buy.stripe.com/aEU5kuc0Ofek4qQ001',
- '84' => 'https://buy.stripe.com/9AQ8wG8OCfek9LaaEI',
- '94' => 'https://buy.stripe.com/3cs28i6GuaY4f5ueUZ',
- '114' => 'https://buy.stripe.com/14k00ae8W2ryg9y28a',
- '124' => 'https://buy.stripe.com/cN2fZ81mac28g9ydQT',
- '134' => 'https://buy.stripe.com/28o4gq0i67LSe1q8wD',
- '144' => 'https://buy.stripe.com/cN214ec0O1nuf5u6ow',
- '184' => 'https://buy.stripe.com/9AQ8wGe8W0jq1eEdQZ',
- '194' => 'https://buy.stripe.com/bIY5kugh4gioe1qeV6',
- '334' => 'https://buy.stripe.com/9AQfZ80i6gio8H64gq',
+ '47' => 'https://buy.stripe.com/28odR0aWK0jq0aAeV0',
+ '67' => 'https://buy.stripe.com/8wMaEO0i67LS1eE288',
+ '77' => 'https://buy.stripe.com/aEU5kuc0Ofek4qQ001',
+ '97' => 'https://buy.stripe.com/3cs28i6GuaY4f5ueUZ',
+ '117' => 'https://buy.stripe.com/14k00ae8W2ryg9y28a',
+ '127' => 'https://buy.stripe.com/cN2fZ81mac28g9ydQT',
+ '147' => 'https://buy.stripe.com/cN214ec0O1nuf5u6ow',
+ '277' => 'https://buy.stripe.com/28o5kuaWK6HO3mMeV8',
+ '337' => 'https://buy.stripe.com/9AQfZ80i6gio8H64gq',
);
# fuction to parse _deploy.conf and vm*.txt files
blob - 5b45ab9ee02d257dfdbbee678f84402ed26079e5
blob + 85238d5fa17722373d6ba8b0ab956017b96b9a54
--- startall.sh
+++ startall.sh
#!/bin/sh
#
-# Copyright (c) 2019-2021 Mischa Peters <mischa @ openbsd.amsterdam>
+# Copyright (c) 2019-2023 Mischa Peters <mischa @ openbsd.amsterdam>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#
+DELAY=0
SLEEP=240
CPU=$(($(sysctl -n hw.ncpuonline)-2))
COUNTER=0
for i in ${VMS[*]}; do
COUNTER=$((${COUNTER}+1))
- vmctl start ${i} ; sleep 5
+ vmctl start ${i} ; sleep ${DELAY}
if [ $COUNTER -eq $CPU ]; then
sleep ${SLEEP}
COUNTER=0
blob - bfe52f4b1079ea5586510c65b2da4f91eb3d5078
blob + 4f8007c8bf0325196240b911a0296850956e4e7d
--- stopall.sh
+++ stopall.sh
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#
+DELAY=0
SLEEP=30
CPU=$(($(sysctl -n hw.ncpuonline)-2))
COUNTER=0
for i in ${VMS[*]}; do
COUNTER=$((${COUNTER}+1))
- vmctl stop ${i}
+ vmctl stop ${i} ; sleep ${DELAY}
if [ $COUNTER -eq $CPU ]; then
sleep ${SLEEP}
COUNTER=0