Skip to content
Snippets Groups Projects
Commit f1ba5b51 authored by Cam Saul's avatar Cam Saul
Browse files

release script template fixes

parent fbb46416
Branches
Tags
No related merge requests found
......@@ -2,6 +2,7 @@
(:require [cheshire.core :as json]
[clj-http.client :as http]
[clojure.core.cache :as cache]
[clojure.java.io :as io]
[metabuild-common.core :as u]
[release.common :as c]
[release.common
......@@ -14,7 +15,9 @@
(stencil.loader/set-cache (cache/ttl-cache-factory {} :ttl 0))
(def ^:private release-template-filename
(u/assert-file-exists (u/filename c/root-directory "bin" "release" "src" "release" "draft_release" "release-template.md")))
"release/draft_release/release-template.md")
(u/assert-file-exists (.getPath (io/resource release-template-filename)))
(defn- generate-draft-changelog []
(u/step "Generate draft changelog"
......
......@@ -2,6 +2,7 @@
"Code related to building and publishing Elastic Beanstalk artifacts."
(:require [cheshire.core :as json]
[clojure.core.cache :as cache]
[clojure.java.io :as io]
[metabuild-common.core :as u]
[release.common :as c]
[release.common
......@@ -82,16 +83,18 @@
(u/assert-file-exists archive-path))))
(def ^:private launch-template-filename
(u/assert-file-exists (u/filename c/root-directory "bin" "release" "src" "release" "elastic_beanstalk" "launch-aws-eb.html.template")))
"release/elastic_beanstalk/launch-aws-eb.html.template")
(u/assert-file-exists (.getPath (io/resource launch-template-filename)))
(defn- create-html-file! []
(u/step (format "Create launch-aws-eb.html for Docker image %s" (c/docker-tag))
(u/delete-file-if-exists! html-file-path)
(spit html-file-path
(stencil/render-file launch-template-filename
{:url (java.net.URLEncoder/encode (c/artifact-download-url "metabase-aws-eb.zip")
"UTF-8")}))
(u/assert-file-exists html-file-path)))
(u/delete-file-if-exists! html-file-path)
(spit html-file-path
(stencil/render-file launch-template-filename
{:url (java.net.URLEncoder/encode (c/artifact-download-url "metabase-aws-eb.zip")
"UTF-8")}))
(u/assert-file-exists html-file-path)))
(defn- upload-artifacts! []
(u/step "Upload Elastic Beanstalk artifacts"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment