Skip to content

Commit

Permalink
0.2.10
Browse files Browse the repository at this point in the history
  • Loading branch information
sebt3 committed May 9, 2024
1 parent 164a5e0 commit 4d6615f
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 17 deletions.
12 changes: 6 additions & 6 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "vynil"
version = "0.2.9"
version = "0.2.10"
authors = ["Sébastien Huss <sebastien.huss@gmail.com>"]
edition = "2021"
license = " BSD-3-Clause"
Expand Down
2 changes: 1 addition & 1 deletion agent/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "agent"
version = "0.2.9"
version = "0.2.10"
authors = ["Sébastien Huss <sebastien.huss@gmail.com>"]
edition = "2021"
license = " BSD-3-Clause"
Expand Down
2 changes: 1 addition & 1 deletion dist/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "dist"
version = "0.2.9"
version = "0.2.10"
authors = ["Sébastien Huss <sebastien.huss@gmail.com>"]
edition = "2021"
license = " BSD-3-Clause"
Expand Down
7 changes: 4 additions & 3 deletions dist/src/pack.rs
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ pub fn run(args:&Parameters) -> Result<()> {
let dest_dir = fs::canonicalize(&tmp).unwrap();

// Start the script engine
let mut script = script::Script::from_dir(&path.clone(), &"pack".to_string(), script::new_context(
let stage = "pack".to_string();
let mut script = script::Script::from_dir(&path.clone(), &stage, script::new_context(
yaml.category.clone(),
yaml.metadata.name.clone(),
yaml.metadata.name.clone(),
Expand All @@ -87,13 +88,13 @@ pub fn run(args:&Parameters) -> Result<()> {
&yaml.get_values(&serde_json::Map::new())
));
// run the pre-pack stage if any
let stage = "pack".to_string();
match script.run_pre_stage(&stage) {Ok(_) => {}, Err(e) => {return Err(e)}}
// look source directory
let mut copies: Vec<PathBuf> = Vec::new();
let re_kusto = Regex::new(r"^kustomization\.yaml$").unwrap();
let re_kustohbs = Regex::new(r"^kustomization\.yaml\.hbs$").unwrap();
let re_rhai = Regex::new(r"\.rhai$").unwrap();
let re_pack = Regex::new(r"pack\.rhai$").unwrap();
let re_hbs = Regex::new(r"\.hbs$").unwrap();
let re_ymlhbs = Regex::new(r"\.yaml\.hbs$").unwrap();
let re_yml = Regex::new(r"\.yaml$").unwrap();
Expand Down Expand Up @@ -123,7 +124,7 @@ pub fn run(args:&Parameters) -> Result<()> {
use_templates = true;
copies.push(path);
} else if re_tf.is_match(filename) ||
(re_rhai.is_match(filename) && (script.have_stage("install") || script.have_stage("destroy") || script.have_stage("plan") || script.have_stage("template"))) {
(re_rhai.is_match(filename) && !re_pack.is_match(filename)) {
copies.push(path);
}
}
Expand Down
2 changes: 1 addition & 1 deletion k8s/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "k8s"
version = "0.2.9"
version = "0.2.10"
edition = "2021"
license = " BSD-3-Clause"

Expand Down
2 changes: 1 addition & 1 deletion operator/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "operator"
version = "0.2.9"
version = "0.2.10"
authors = ["Sébastien Huss <sebastien.huss@gmail.com>"]
edition = "2021"
default-run = "operator"
Expand Down
4 changes: 2 additions & 2 deletions operator/src/install.rs
Original file line number Diff line number Diff line change
Expand Up @@ -223,15 +223,15 @@ impl Reconciler for Install {
events::from_delete("Install", &name, "Job", &job.name_any(), Some(job.object_ref(&())))
).await.map_err(Error::KubeError)?;
jobs.delete(agent_name.as_str()).await.unwrap();
error!("Recreating {agent_name} Job");
info!("Recreating {agent_name} Job");
recorder.publish(
events::from_create("Install", &name, "Job", &job.name_any(), Some(job.object_ref(&())))
).await.map_err(Error::KubeError)?;
jobs.create_install(agent_name.as_str(), &agent_job, action, name.as_str(), ns.as_str()).await.unwrap()
}};
if let Some(status) = job.status {
if status.completion_time.is_none() {
error!("Waiting after {agent_name} Job");
info!("Waiting after {agent_name} Job");
recorder.publish(
events::from_check("Install", &name, "Bootstrap in progress, requeue".to_string(), None)
).await.map_err(Error::KubeError)?;
Expand Down
2 changes: 1 addition & 1 deletion package/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "package"
version = "0.2.9"
version = "0.2.10"
authors = ["Sébastien Huss <sebastien.huss@gmail.com>"]
edition = "2021"
license = " BSD-3-Clause"
Expand Down

0 comments on commit 4d6615f

Please sign in to comment.