Deploy Using Vagrant and Ansible
Introudction
Vagrant and Ansible can be used to quickly build or rebuild virtual servers. ArcherySec can be configured using Vagrant and Ansible and in this example we’ll going to deploy archerysec automatically using Ansible on Ubuntu Server.
DO NOT EXPOSE PUBLICLY, INTERNAL USE ONLY
Prerequisites
- Varant
- VirtualBox
- Ansible
Deploy ArcherySec using Vagrant and Ansible
- Run the following commands to setup:
# Clone Git repositiory
git clone https://github.com/archerysec/archerysec-vagrant-ansible.git
# Move into directory
cd archerysec-vagrant-ansible
# Run vagrant command to provision archerysec server
vagrant up --provision
- Access the archerysec by using link http://archerysec.local/
- Default Username:
archerysec@archerysec.lab
- Default Password:
test@123A
File Structure
├── README.md
├── Vagrantfile
├── playbook.yml
├── roles
│ ├── defaults
│ │ └── main.yml
│ ├── handlers
│ │ └── main.yml
│ ├── tasks
│ │ └── main.yml
│ └── templates
│ ├── archerysec.service
│ ├── django_bootstrap.conf
│ ├── gunicorn_start
│ └── nginx.conf
└── ubuntu-bionic-18.04-cloudimg-console.log
Change Default Password
If you want to change Default password of ArcherySec follow the below instruction.
- Edit file roles main.yml file in path
roles/defaults/main.yml
- Change the vaule of
admin_email
andadmin_pass
- Run the vageant previsining command:
vagrant up --provision
- Access they URL http://archerysec.local/ and provide new credentials
Change Default Database Instance
If you want to change Database Default Credential follow the below instruction.
- Edit file roles main.yml file in path
roles/defaults/main.yml
- Change the vaule of
db_user
,db_password
,db_host
anddb_name
- Run the vageant previsining command:
vagrant up --provision
Change Django Default Secret Key
- Edit file roles main.yml file in path
roles/defaults/main.yml
- Change the vaule of
django_secret_key
- Run the vageant previsining command:
vagrant up --provision