diff --git a/.gitignore b/.gitignore index 8cdaa33..eab0e5d 100644 --- a/.gitignore +++ b/.gitignore @@ -11,3 +11,5 @@ node_modules/ test-results/ end2end/playwright-report/ playwright/.cache/ + +venv diff --git a/helm/tools/update_yaml.py b/helm/tools/update_yaml.py new file mode 100644 index 0000000..5f82aaf --- /dev/null +++ b/helm/tools/update_yaml.py @@ -0,0 +1,34 @@ +import sys +from ruamel.yaml import YAML + +def update_yaml(file_path, path_to_update, new_value): + yaml = YAML() + yaml.preserve_quotes = True # Optional, to preserve the original quotation marks + + # Load the YAML file + with open(file_path, 'r') as file: + data = yaml.load(file) + + # Split the path to navigate through the YAML structure + keys = path_to_update.strip('.').split('.') + # Access the nested dictionary and update the value + temp = data + for key in keys[:-1]: + temp = temp[key] + temp[keys[-1]] = new_value + + # Write the YAML file back + with open(file_path, 'w') as file: + yaml.dump(data, file) + +if __name__ == "__main__": + if len(sys.argv) != 4: + print("Usage: python update_yaml.py <.path.to.key> ") + sys.exit(1) + + file_path = sys.argv[1] + path_to_update = sys.argv[2] + new_value = sys.argv[3] + + update_yaml(file_path, path_to_update, new_value) + diff --git a/sreez/assets/sreez_logo_shaded_v2.png b/sreez/assets/sreez_logo_shaded_v2.png index bab43c8..391d6e4 100644 Binary files a/sreez/assets/sreez_logo_shaded_v2.png and b/sreez/assets/sreez_logo_shaded_v2.png differ diff --git a/sreez/assets/sreez_logo_shaded_v2_fullsize.png b/sreez/assets/sreez_logo_shaded_v2_fullsize.png new file mode 100644 index 0000000..bab43c8 Binary files /dev/null and b/sreez/assets/sreez_logo_shaded_v2_fullsize.png differ diff --git a/sreez/build_docker.sh b/sreez/build_docker.sh index d3be08c..7b7e510 100755 --- a/sreez/build_docker.sh +++ b/sreez/build_docker.sh @@ -8,11 +8,17 @@ fi REGISTRY=registry.nationtech.io IMAGE_NAME=sreez-website -TAG="${1}" +TAG="v1.1.0" IMAGE="${REGISTRY}/${IMAGE_NAME}:${TAG}" echo "Going to build and push image ${IMAGE}" docker build -t "${IMAGE}" . -# docker push "${1}" + +docker push "${IMAGE}" + +echo "Image is built and pushed, do you want to commit and deploy this new version ? (enter to continue, CTRL+C to abort" +read + +python ../helm/tools/update_yaml.py ../helm/sreez-website/values.yaml .image.tag "${TAG}" diff --git a/sreez/src/components/book_a_demo.rs b/sreez/src/components/book_a_demo.rs index 131b674..0136bd1 100644 --- a/sreez/src/components/book_a_demo.rs +++ b/sreez/src/components/book_a_demo.rs @@ -1,7 +1,10 @@ use leptos::*; #[component] -pub fn BookADemo() -> impl IntoView { +pub fn BookADemo( +#[prop(optional)] +text: String + ) -> impl IntoView { let (is_clicked, set_clicked) = create_signal(false); view! { @@ -10,7 +13,7 @@ pub fn BookADemo() -> impl IntoView { on:click=move |_| { set_clicked.update(|is_clicked| *is_clicked = !*is_clicked) } - >"Book a demo →" + >{text}
diff --git a/sreez/src/components/footer.rs b/sreez/src/components/footer.rs index 58909cd..241c235 100644 --- a/sreez/src/components/footer.rs +++ b/sreez/src/components/footer.rs @@ -2,32 +2,30 @@ use leptos::*; #[component] pub fn Footer() -> impl IntoView { - let (is_clicked, set_clicked) = create_signal(false); - view! {

"Reach us here :"

-

-

-

-