Browse Source

Stop producing chained files

master
Adrian Heine 5 months ago
parent
commit
ff32cda7df
  1. 8
      src/builder.rs
  2. 10
      src/locator.rs

8
src/builder.rs

@ -137,13 +137,13 @@ impl<D: Clone> ImplementationBuilder<CertChain<D>> for DefaultBuilder {
Cert(resource.0.clone())
}
type Implementation = ConcatSymbol<[Rc<Path>; 1], Rc<Path>, Rc<Path>>;
type Implementation = ();
fn create(
_resource: &CertChain<D>,
target: &<CertChain<D> as Resource>::Artifact,
cert: <Self::Prerequisites as ToArtifact>::Artifact,
_target: &<CertChain<D> as Resource>::Artifact,
_cert: <Self::Prerequisites as ToArtifact>::Artifact,
) -> Self::Implementation {
ConcatSymbol::new([cert.clone_rc()], target.clone_rc())
()
}
}

10
src/locator.rs

@ -90,17 +90,11 @@ impl<P, D: AsRef<str>> ResourceLocator<Cert<D>> for DefaultLocator<P> {
}
impl<P, D: AsRef<str>> ResourceLocator<CertChain<D>> for DefaultLocator<P> {
type Prerequisites = Dir<Rc<Path>>;
type Prerequisites = <Self as ResourceLocator<Cert<D>>>::Prerequisites;
fn locate(
resource: &CertChain<D>,
) -> (<CertChain<D> as Resource>::Artifact, Self::Prerequisites) {
(
PathArtifact::from(format!(
"/etc/ssl/local_certs/{}.chained.crt",
resource.0.as_ref()
)),
Dir::new("/etc/ssl/local_certs"),
)
<Self as ResourceLocator<Cert<&D>>>::locate(&Cert(&resource.0))
}
}

Loading…
Cancel
Save