Skip to content

Creating a Private Clojure component Step By Step Guide

mrinalsaurabh edited this page Oct 5, 2017 · 2 revisions

In this example, we are trying to install a go-com project that we have developed in clojure as a dependency in other projects.


Steps to Deploy:

  1. Checkout /go-com.git
  2. Make changes, checkin.
  3. Run lein uberjar in the go-com folder.
  4. Copy this to the jar file to ~/jars folder as: mkdir ~/jars mv /target/go-com-0.1.0-SNAPSHOT.jar ~/jars/go-com-0.1.0.jar
  5. Deploy the repo locally. Update the DVersion everytime. mvn deploy:deploy-file -Dfile=/home/vagrant/jars/go-com-0.1.0.jar -DartifactId=go-com -Dversion=0.1.0 -DgroupId=go-com -Dpackaging=jar -Durl=file:maven_repository -Dmaven.repo.local=maven_repository -DcreateChecksum
  6. Copy it to amazon folder. aws s3 cp /home/vagrant/jars/maven_repository/go-com/go-com/0.1.0 s3://go-com/releases/go-com/go-com/0.1.0 --recursive

Steps to use:

  1. Include it in your project.clj :dependencies section: [go-com/go-com "0.1.0"]
  2. Add a repositories section to the project.clj :repositories {"local" {:url "s3p://go-com/releases/" :username :env/aws_access_key_id :passphrase :env/aws_secret_access_key}}
  3. Set env varialbles export AWS_ACCESS_KEY_ID=<some_access_key> export AWS_SECRET_ACCESS_KEY=<some_secret_key>
  4. lein deps
You can’t perform that action at this time.