Installation
Aztlan was designed from the ground up to be easily installed and used to get your WordPress theme up and running quickly on Docker.
Requirements
Aztlan only requires Docker and Docker Compose (version 1.23 or above). For OSX we recommend installing Docker Sync.
If you dont have Docker, access Docker installation guide.
Pre installation
Docker
In order for the user to run the commands to raise the environment it must be in the docker group.
Listing user groups:
$ groups $USER
Add user to Docker group
$ sudo groupadd docker
$ sudo usermod -aG docker $USER
Docker Sync
For OSX, Aztlan use Docker Sync to improve file read and write performance.
You must run the synchronization command each time you start work in the environment to ensure that the volumes that integrate the application with the file system are synchronized.
$ project-docker-sync
Installing
Directory
Create a root directory for your project:
mkdir my_project && cd my_project
Repository
The following command will download a latest version of the Aztlan environment on my_project
directory:
wget -qO- http://github.com/aztecweb/aztlan/archive/master.tar.gz | tar -xzf - --strip-components 1
Install
Run only one command to install your environment:
$ ./environment/bin/install
If you need change the default installation settings, see configuration page.
Restart installation
If for any reason you have to get a clean installation, just remove all gitignored files and reset your database data.
For this step you must have Git installed.
Removing gitignored files
This command will remove all files that are not versioned by Git. Be very careful not to lose any important files.
$ git clean -xdf
Reseting your database
Clears all WordPress data to allow a fresh install.
$ wp db reset --yes
Profile
Aztlan has a collection of alias to make environment management easier and faster. Load environment profile to your current shell:
$ source /environment/profile
Since the profile is based on the current terminal context, every time that a new terminal is opened to work on the project, it is necessary to load the profile.
Click here to see the list of all commands.
Running
Now with the profile loaded just run the command below to start the server, your Aztlan environment will be running on localhost:
$ server
And run down
to stop all started containers.