chore: Rename nationtec-io folder to sreez
This commit is contained in:
53
sreez/src/app.rs
Normal file
53
sreez/src/app.rs
Normal file
@@ -0,0 +1,53 @@
|
||||
use leptos::*;
|
||||
use leptos_meta::*;
|
||||
use leptos_router::*;
|
||||
|
||||
use crate::pages::HomePage;
|
||||
|
||||
#[component]
|
||||
pub fn App() -> impl IntoView {
|
||||
// Provides context that manages stylesheets, titles, meta tags, etc.
|
||||
provide_meta_context();
|
||||
|
||||
view! {
|
||||
// injects a stylesheet into the document <head>
|
||||
// id=leptos means cargo-leptos will hot-reload this stylesheet
|
||||
<Stylesheet id="leptos" href="/pkg/nationtech-io.css"/>
|
||||
|
||||
// sets the document title
|
||||
<Title text="SREEZ - Site Reliability Engineering for Everyone, eZ"/>
|
||||
|
||||
// content for this welcome page
|
||||
<Router>
|
||||
<main>
|
||||
<Routes>
|
||||
<Route path="" view=HomePage/>
|
||||
<Route path="/*any" view=NotFound/>
|
||||
</Routes>
|
||||
</main>
|
||||
</Router>
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// 404 - Not Found
|
||||
#[component]
|
||||
fn NotFound() -> impl IntoView {
|
||||
// set an HTTP status code 404
|
||||
// this is feature gated because it can only be done during
|
||||
// initial server-side rendering
|
||||
// if you navigate to the 404 page subsequently, the status
|
||||
// code will not be set because there is not a new HTTP request
|
||||
// to the server
|
||||
#[cfg(feature = "ssr")]
|
||||
{
|
||||
// this can be done inline because it's synchronous
|
||||
// if it were async, we'd use a server function
|
||||
let resp = expect_context::<leptos_actix::ResponseOptions>();
|
||||
resp.set_status(actix_web::http::StatusCode::NOT_FOUND);
|
||||
}
|
||||
|
||||
view! {
|
||||
<h1>"Not Found"</h1>
|
||||
}
|
||||
}
|
||||
13
sreez/src/lib.rs
Normal file
13
sreez/src/lib.rs
Normal file
@@ -0,0 +1,13 @@
|
||||
pub mod app;
|
||||
mod pages;
|
||||
|
||||
#[cfg(feature = "hydrate")]
|
||||
#[wasm_bindgen::prelude::wasm_bindgen]
|
||||
pub fn hydrate() {
|
||||
use app::*;
|
||||
use leptos::*;
|
||||
|
||||
console_error_panic_hook::set_once();
|
||||
|
||||
mount_to_body(App);
|
||||
}
|
||||
68
sreez/src/main.rs
Normal file
68
sreez/src/main.rs
Normal file
@@ -0,0 +1,68 @@
|
||||
#[cfg(feature = "ssr")]
|
||||
#[actix_web::main]
|
||||
async fn main() -> std::io::Result<()> {
|
||||
use actix_files::Files;
|
||||
use actix_web::*;
|
||||
use leptos::*;
|
||||
use leptos_actix::{generate_route_list, LeptosRoutes};
|
||||
use nationtech_io::app::*;
|
||||
|
||||
let conf = get_configuration(None).await.unwrap();
|
||||
let addr = conf.leptos_options.site_addr;
|
||||
// Generate the list of routes in your Leptos App
|
||||
let routes = generate_route_list(App);
|
||||
println!("listening on http://{}", &addr);
|
||||
|
||||
HttpServer::new(move || {
|
||||
let leptos_options = &conf.leptos_options;
|
||||
let site_root = &leptos_options.site_root;
|
||||
|
||||
App::new()
|
||||
// serve JS/WASM/CSS from `pkg`
|
||||
.service(Files::new("/pkg", format!("{site_root}/pkg")))
|
||||
// serve other assets from the `assets` directory
|
||||
.service(Files::new("/assets", site_root))
|
||||
// serve the favicon from /favicon.ico
|
||||
.service(favicon)
|
||||
.leptos_routes(leptos_options.to_owned(), routes.to_owned(), App)
|
||||
.app_data(web::Data::new(leptos_options.to_owned()))
|
||||
//.wrap(middleware::Compress::default())
|
||||
})
|
||||
.bind(&addr)?
|
||||
.run()
|
||||
.await
|
||||
}
|
||||
|
||||
#[cfg(feature = "ssr")]
|
||||
#[actix_web::get("favicon.ico")]
|
||||
async fn favicon(
|
||||
leptos_options: actix_web::web::Data<leptos::LeptosOptions>,
|
||||
) -> actix_web::Result<actix_files::NamedFile> {
|
||||
let leptos_options = leptos_options.into_inner();
|
||||
let site_root = &leptos_options.site_root;
|
||||
Ok(actix_files::NamedFile::open(format!(
|
||||
"{site_root}/favicon.ico"
|
||||
))?)
|
||||
}
|
||||
|
||||
#[cfg(not(any(feature = "ssr", feature = "csr")))]
|
||||
pub fn main() {
|
||||
// no client-side main function
|
||||
// unless we want this to work with e.g., Trunk for pure client-side testing
|
||||
// see lib.rs for hydration function instead
|
||||
// see optional feature `csr` instead
|
||||
}
|
||||
|
||||
#[cfg(all(not(feature = "ssr"), feature = "csr"))]
|
||||
pub fn main() {
|
||||
// a client-side main function is required for using `trunk serve`
|
||||
// prefer using `cargo leptos serve` instead
|
||||
// to run: `trunk serve --open --features csr`
|
||||
use leptos::*;
|
||||
use nationtech_io::app::*;
|
||||
use wasm_bindgen::prelude::wasm_bindgen;
|
||||
|
||||
console_error_panic_hook::set_once();
|
||||
|
||||
leptos::mount_to_body(App);
|
||||
}
|
||||
118
sreez/src/pages/home_page.rs
Normal file
118
sreez/src/pages/home_page.rs
Normal file
@@ -0,0 +1,118 @@
|
||||
use leptos::*;
|
||||
/// Renders the home page of your application.
|
||||
#[component]
|
||||
pub fn HomePage() -> impl IntoView {
|
||||
// Creates a reactive value to update the button
|
||||
view! {
|
||||
<div class="row margin-y-4 justify-center">
|
||||
<img src="assets/sreez_transparent_bg.png" alt="SREEZ mascot. Yes it is text-to-image generated by GPT4/DALL·E" class="max-width-400 margin-x-3"/>
|
||||
<div class="margin-x-3 text-left column justify-center">
|
||||
<h1>"SREEZ"
|
||||
<br/>
|
||||
<span class="font-size-xl color-gray">"Site Reliability Engineering for Everyone, eZ"</span>
|
||||
</h1>
|
||||
<h2 class="font-size-3xl">
|
||||
<span>"Stay focused"</span><br/>
|
||||
<span>"on your features,"</span><br/>
|
||||
<span>"we take care"</span><br/>
|
||||
<span>"of the infrastructure."</span>
|
||||
</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row card-list">
|
||||
<div class="card">
|
||||
<h3>"24/7 support"</h3>
|
||||
<ul>
|
||||
<li>"We make sure your infrastructure is running, all the time"</li>
|
||||
<li>"We won't wake you up unless there is a bug in your code"</li>
|
||||
<li>"Full post-mortem and reactive measures taken so it won't happen again"</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="card">
|
||||
<h3>"Batteries included"</h3>
|
||||
<ul>
|
||||
<li>"Managed Orchestrator : RedHat OpenShift Community (OKD) cluster"</li>
|
||||
<li>"Marketplace : Easily install hundreds of apps, databases, productivity tools at no additional cost"</li>
|
||||
<li>"CI/CD Pipeline : Source Control, Continuous Integration, Test Automation, Static Analysis, Continuous Delivery"</li>
|
||||
<li>"AI Tools : Open source LLMs, Model Management and Deployment, Jupyter Notebooks, NVidia GPUs"</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="card">
|
||||
<h3>"Free as a byte"</h3>
|
||||
<ul>
|
||||
<li>"No vendor lock-in, only open source tools"</li>
|
||||
<li>"Install any software based on your specific needs only"</li>
|
||||
<li>"Run anywhere : NationTech Network, Bare Metal, Virtual Machines, Public Cloud, Private Cloud"</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<p>"And much more, just "<a href="mailto:sreez@nationtech.io">"ask us!"</a></p>
|
||||
<h2>"How it works"</h2>
|
||||
<div class="md-container text-left">
|
||||
<ol class="huge-list-markers">
|
||||
<li><h3 class="text-3x">"Fork a template repo"</h3></li>
|
||||
<li><h3 class="text-3x">"Create an account"</h3></li>
|
||||
<li><h3 class="text-3x">"Push a modification"</h3></li>
|
||||
<li><h3 class="text-3x">"Enjoy life in production"</h3></li>
|
||||
</ol>
|
||||
</div>
|
||||
<div class="row card-list">
|
||||
<div class="card">
|
||||
<h3 class="border-bottom-4">"Base package - Self Managed"</h3>
|
||||
<ul class="text-left">
|
||||
<li>"1 Kubernetes namespace - Auto-Healing, Auto-Scaling, Fully Managed"</li>
|
||||
<li>"Kubeapps dashboard - install hundreds of applications and databases in 1 click"</li>
|
||||
<li>"Argo-CD"</li>
|
||||
<li>"Gitea"</li>
|
||||
<li>"Jenkins"</li>
|
||||
<li>"Prometheus"</li>
|
||||
<li>"Grafana"</li>
|
||||
<li>"64 GB RAM"</li>
|
||||
<li>"32 CPU Cores"</li>
|
||||
<li>"2 TB General Purpose Distributed Storage"</li>
|
||||
</ul>
|
||||
<div class="spacer"></div>
|
||||
<p class="font-bold text-center text-4">"1 055 CAD / Month"</p>
|
||||
<p class="font-bold text-center text-4">"10 555 CAD / Year"</p>
|
||||
</div>
|
||||
<div class="card">
|
||||
<h3 class="border-bottom-4">"Startup Package - SRE as a Service"</h3>
|
||||
<ul class="text-left">
|
||||
<li>"Everything in lower package, plus"</li>
|
||||
<li>"Unlimited Kubernetes namespaces - Auto-Healing, Auto-Scaling, Fully Managed"</li>
|
||||
<li>"Kubeflow"</li>
|
||||
<li>"OpenLLM - LLaMa, Mistral, StarCoder and more open source models to tune and run privately"</li>
|
||||
<li>"1 AI GPU with 24GB+ VRAM"</li>
|
||||
<li>"256 GB RAM"</li>
|
||||
<li>"96 CPU Cores"</li>
|
||||
<li>"10 TB General Purpose Distributed Storage"</li>
|
||||
<li>"2 hours per month complimentary consulting with our SRE team"</li>
|
||||
<li>"Access to direct messaging with 4 hour SLA 24/7"</li>
|
||||
</ul>
|
||||
<div class="spacer"></div>
|
||||
<p class="margin-x-1">"For those who have modest needs but want to benefit from the best SRE tools and teams in the industry"</p>
|
||||
<p class="font-bold text-center text-4">"5 555 CAD / Month"</p>
|
||||
<p class="font-bold text-center text-4">"55 555 CAD / Year"</p>
|
||||
</div>
|
||||
<div class="card">
|
||||
<h3 class="border-bottom-4">"Top Package - Dedicated Cluster"</h3>
|
||||
<ul class="text-left">
|
||||
<li>"Everything in lower package, plus"</li>
|
||||
<li>"2 Dedicated OKD (OpenShift Community) Clusters"</li>
|
||||
<li>"Distributed in two geographical sites of your choice"</li>
|
||||
<li>"4 days per month SRE development and improvement on your stack"</li>
|
||||
<li>"4 AI GPUs with 24GB+ VRAM"</li>
|
||||
<li>"4 000 GB RAM"</li>
|
||||
<li>"500 CPU Cores"</li>
|
||||
<li>"1 200 TB General Purpose Distributed Storage"</li>
|
||||
</ul>
|
||||
<div class="spacer"></div>
|
||||
<p class="margin-x-1">"We can customize our offering around this base package. Let us know what you need."</p>
|
||||
<p class="margin-x-1">"We can deliver, fast : 2 clusters available within 3 days."</p>
|
||||
<p class="margin-x-1">"1 month lead time for more clusters."</p>
|
||||
<p class="font-bold text-center text-4">"55 555 CAD / Month"</p>
|
||||
<p class="font-bold text-center text-4">"555 555 CAD / Year"</p>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
2
sreez/src/pages/mod.rs
Normal file
2
sreez/src/pages/mod.rs
Normal file
@@ -0,0 +1,2 @@
|
||||
mod home_page;
|
||||
pub use home_page::*;
|
||||
Reference in New Issue
Block a user