CHEF PROVED TO BE AN UNRELYABLE TOOL AND WE'RE MOVING TO DOCKER, SEE OUR FIRST STEPS [HERE] (https://github.com/jtalks-org/jtalks-cicd).
If you want to start a brand new environment for JTalks with installed software using just a couple of commands - then this is what you're looking for. This project helps you to start a virtual environment using Vagrant + Chef scripts.
In order to start one of JTalks component, you need to go through several steps. ####Install Software
- Install VirtualBox which is an Oracle driven tool for starting virtual environments. Vagrant started to support VMWare, but we didn't test our scripts with it.
- Install Vagrant. It's an extremely simple tool that can start virtual environment and install software there using Chef or Puppet scripts.
- Download this project either in zip format or grab sources using Git. Unpack if needed and step into the folder.
####Start virtual environment
vagrant up
- this starts your env and runs Chef scripts. This may take a lot of time especially first time because it downloads software and virtual image from the internet.vagrant ssh
- log into the just created virtual machine. For Windows users you'll have to use Putty to log in via SSH. UseHost: localhost
,Port: 2222
. User:vagrant
, password:vagrant
.
####Start JCommune or Poulpe
jtalks deploy --environment vagrant --project jcommune --build 2037
- this is just an example that start 2037th build of JCommune project.- Instead of
jcommmune
you can specifypoulpe
to start Poulpe. - Instead of
2037
you need to put a build you'd like to use, a list of them can be found in our Deployment Pipeline Repository. Every build has a suffix following major and minor version of the build. - Now if everything is green (if not, read below), go to your browser and run http://localhost:4000/jcommune or http://localhost:4000/poulpe and here we are.
- The configuration is kept in
~/.jtalks
and can be changed if needed. For more information on how to install and use jtalks scripts see JTalks CICD project
####Shutdown environment
- Log out from virtual box, you still should be in
jtalks-vm
folder. - You can either destroy everything wiping off databases by using
vagrant destroy
. After that you'll be able to start a brand new env again by runningvagrant up
- Or you can simply shut down environment
vagrant suspend
and to continue work with it:vagrant resume
The very same cookbooks could be used on usual servers that don't leverage virtualization. E.g. we use them in order to install software, see folder roles
. In order to install everything onto the machine, feel free to leverage install-chef script. After installation you can go to /var/chef/jtalks-vm
and install software using server roles, e.g.: sudo chef-solo -j roles/jtalks-servers.json
If you have problems, please contact us: project[at]jtalks[.]org