containeryard 0.3.5

Container Yard is a declarative, reproducible, and reusable decentralized approach for defining containers. Think Nix flakes meets Containerfiles (aka Dockerfiles).
1
2
3
4
5
6
7
8
9
10
11
12
use std::path::Path;

use tokio::fs;

use crate::build::YARD_YAML_FILE_NAME;

pub async fn init(path: &Path) -> anyhow::Result<()> {
    let template_file = path.join(YARD_YAML_FILE_NAME);
    let simple_template = include_str!("templates/simple/yard.yaml");
    fs::write(template_file, simple_template).await?;
    Ok(())
}