fixed installers
This commit is contained in:
@@ -6,7 +6,7 @@ import freeflowuniverse.herolib.osal.zinit
|
||||
import os
|
||||
|
||||
// checks if a certain version or above is installed
|
||||
fn installed() !bool {
|
||||
fn installed_() !bool {
|
||||
// THIS IS EXAMPLE CODEAND NEEDS TO BE CHANGED
|
||||
// res := os.execute('${osal.profile_path_source_and()} caddy version')
|
||||
// if res.exit_code != 0 {
|
||||
@@ -22,7 +22,7 @@ fn installed() !bool {
|
||||
return true
|
||||
}
|
||||
|
||||
fn install() ! {
|
||||
fn install_() ! {
|
||||
console.print_header('install caddy')
|
||||
|
||||
mut cfg := get()!
|
||||
@@ -113,7 +113,7 @@ pub fn configure_examples(config WebConfig) ! {
|
||||
configuration_set(content: config_file)!
|
||||
}
|
||||
|
||||
fn running() !bool {
|
||||
fn running_() !bool {
|
||||
mut cfg := get()!
|
||||
|
||||
// THIS IS EXAMPLE CODEAND NEEDS TO BE CHANGED
|
||||
@@ -137,7 +137,7 @@ fn running() !bool {
|
||||
return true
|
||||
}
|
||||
|
||||
fn destroy() ! {
|
||||
fn destroy_() ! {
|
||||
// THIS IS EXAMPLE CODEAND NEEDS TO BE CHANGED
|
||||
// cmd:="
|
||||
// systemctl disable caddy_scheduler.service
|
||||
|
||||
@@ -25,7 +25,7 @@ pub const version = '2.8.4'
|
||||
// }
|
||||
|
||||
// // install caddy will return true if it was already installed
|
||||
// pub fn install(args_ InstallArgs) ! {
|
||||
// pub fn install_(args_ InstallArgs) ! {
|
||||
// mut args := args_
|
||||
// version := '2.8.4'
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ import os
|
||||
const installername = os.base(os.dir(@FILE))
|
||||
|
||||
// install imagemagick will return true if it was already installed
|
||||
pub fn install() ! {
|
||||
pub fn install_() ! {
|
||||
console.print_header('install ${installername}')
|
||||
if !osal.done_exists('install_${installername}') {
|
||||
osal.package_install('imagemagick')!
|
||||
|
||||
@@ -27,7 +27,7 @@ fn startupcmd() ![]zinit.ZProcessNewArgs {
|
||||
return res
|
||||
}
|
||||
|
||||
fn running() !bool {
|
||||
fn running_() !bool {
|
||||
mut installer := get()!
|
||||
// THIS IS EXAMPLE CODEAND NEEDS TO BE CHANGED
|
||||
// this checks health of imagemagick
|
||||
@@ -64,7 +64,7 @@ fn stop_post() ! {
|
||||
//////////////////// following actions are not specific to instance of the object
|
||||
|
||||
// checks if a certain version or above is installed
|
||||
fn installed() !bool {
|
||||
fn installed_() !bool {
|
||||
// THIS IS EXAMPLE CODEAND NEEDS TO BE CHANGED
|
||||
// res := os.execute('${osal.profile_path_source_and()} imagemagick version')
|
||||
// if res.exit_code != 0 {
|
||||
@@ -87,14 +87,14 @@ fn ulist_get() !ulist.UList {
|
||||
}
|
||||
|
||||
// uploads to S3 server if configured
|
||||
fn upload() ! {
|
||||
fn upload_() ! {
|
||||
// installers.upload(
|
||||
// cmdname: 'imagemagick'
|
||||
// source: '${gitpath}/target/x86_64-unknown-linux-musl/release/imagemagick'
|
||||
// )!
|
||||
}
|
||||
|
||||
fn install() ! {
|
||||
fn install_() ! {
|
||||
console.print_header('install imagemagick')
|
||||
// THIS IS EXAMPLE CODEAND NEEDS TO BE CHANGED
|
||||
// mut url := ''
|
||||
@@ -125,7 +125,7 @@ fn install() ! {
|
||||
// )!
|
||||
}
|
||||
|
||||
fn build() ! {
|
||||
fn build_() ! {
|
||||
// url := 'https://github.com/threefoldtech/imagemagick'
|
||||
|
||||
// make sure we install base on the node
|
||||
@@ -154,7 +154,7 @@ fn build() ! {
|
||||
// )!
|
||||
}
|
||||
|
||||
fn destroy() ! {
|
||||
fn destroy_() ! {
|
||||
// mut systemdfactory := systemd.new()!
|
||||
// systemdfactory.destroy("zinit")!
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ fn startupcmd() ![]zinit.ZProcessNewArgs {
|
||||
return res
|
||||
}
|
||||
|
||||
fn running() !bool {
|
||||
fn running_() !bool {
|
||||
mut installer := get()!
|
||||
// THIS IS EXAMPLE CODEAND NEEDS TO BE CHANGED
|
||||
// this checks health of lighttpd
|
||||
@@ -64,7 +64,7 @@ fn stop_post() ! {
|
||||
//////////////////// following actions are not specific to instance of the object
|
||||
|
||||
// checks if a certain version or above is installed
|
||||
fn installed() !bool {
|
||||
fn installed_() !bool {
|
||||
// THIS IS EXAMPLE CODEAND NEEDS TO BE CHANGED
|
||||
// res := os.execute('${osal.profile_path_source_and()} lighttpd version')
|
||||
// if res.exit_code != 0 {
|
||||
@@ -87,14 +87,14 @@ fn ulist_get() !ulist.UList {
|
||||
}
|
||||
|
||||
// uploads to S3 server if configured
|
||||
fn upload() ! {
|
||||
fn upload_() ! {
|
||||
// installers.upload(
|
||||
// cmdname: 'lighttpd'
|
||||
// source: '${gitpath}/target/x86_64-unknown-linux-musl/release/lighttpd'
|
||||
// )!
|
||||
}
|
||||
|
||||
fn install() ! {
|
||||
fn install_() ! {
|
||||
console.print_header('install lighttpd')
|
||||
// THIS IS EXAMPLE CODEAND NEEDS TO BE CHANGED
|
||||
// mut url := ''
|
||||
@@ -125,7 +125,7 @@ fn install() ! {
|
||||
// )!
|
||||
}
|
||||
|
||||
fn build() ! {
|
||||
fn build_() ! {
|
||||
// url := 'https://github.com/threefoldtech/lighttpd'
|
||||
|
||||
// make sure we install base on the node
|
||||
@@ -154,7 +154,7 @@ fn build() ! {
|
||||
// )!
|
||||
}
|
||||
|
||||
fn destroy() ! {
|
||||
fn destroy_() ! {
|
||||
// mut systemdfactory := systemd.new()!
|
||||
// systemdfactory.destroy("zinit")!
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ import os
|
||||
pub const version = '3.4.12'
|
||||
|
||||
// checks if a certain version or above is installed
|
||||
fn installed() !bool {
|
||||
fn installed_() !bool {
|
||||
res := os.execute('tailwind -h')
|
||||
if res.exit_code == 0 {
|
||||
r := res.output.split_into_lines().filter(it.contains('tailwindcss v'))
|
||||
@@ -26,7 +26,7 @@ fn installed() !bool {
|
||||
return false
|
||||
}
|
||||
|
||||
pub fn install() ! {
|
||||
pub fn install_() ! {
|
||||
console.print_header('install tailwind')
|
||||
|
||||
mut url := ''
|
||||
@@ -54,5 +54,5 @@ pub fn install() ! {
|
||||
)!
|
||||
}
|
||||
|
||||
fn destroy() ! {
|
||||
fn destroy_() ! {
|
||||
}
|
||||
|
||||
@@ -11,7 +11,7 @@ import os
|
||||
pub const version = '0.18.0'
|
||||
|
||||
// checks if a certain version or above is installed
|
||||
fn installed() !bool {
|
||||
fn installed_() !bool {
|
||||
res := os.execute('${osal.profile_path_source_and()} zola -V')
|
||||
myversion := res.output.all_after(' ')
|
||||
if res.exit_code == 0 {
|
||||
@@ -24,7 +24,7 @@ fn installed() !bool {
|
||||
return false
|
||||
}
|
||||
|
||||
fn install() ! {
|
||||
fn install_() ! {
|
||||
console.print_header('install zola')
|
||||
|
||||
// make sure we install base on the node
|
||||
@@ -61,7 +61,7 @@ fn install() ! {
|
||||
}
|
||||
|
||||
// install zola will return true if it was already installed
|
||||
fn build() ! {
|
||||
fn build_() ! {
|
||||
rust.install()!
|
||||
console.print_header('install zola')
|
||||
cmd := '
|
||||
@@ -80,5 +80,5 @@ fn build() ! {
|
||||
console.print_header('zola installed')
|
||||
}
|
||||
|
||||
fn destroy() ! {
|
||||
fn destroy_() ! {
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user