Skip to content

UNIwise/backend-assignment

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Assignment

The assignment is intended to assist us in assessing your abilities to design solid architectures and write the code to support these. The assignment should open up for discussions in varous topics like testing, scalability, performance, maintainability, extendability etc..

The aim of the assigment is to make some REST endpoints to work with cars. The cars have a brand, model, color, gas economy and a list of extra accessories.

There should be an endpoint to list all cars from the database There should be an endpoint to filter the view of the cars and sort them. It should be possible to filter and sort on various things like equipment

The endpoint should return JSON. It's not the aim of the assignment to make any UI

There's a mysql database in the docker instance that is reachable on localhost:3306 with user: wiseflow and password: test.

The intention is to use Doctrine to describe entities in the database.

However, the important focus is not necessarily on the frameworks, but on your ability to design and write code. For good measure two of our main PHP frameworks we currently use are Doctrine and Symfony, but using these frameworks is not a requirement.

Setup (this is not required for the interview/test)

When entities are create the following command can be run to create/update tables in database:

  1. Make run .

To have the system up and running the following should be installed on the computer:

Docker
Docker-compose

Virtual Machine (VM)

Good luck :)

PS: The password for the 'developer' user is 'test'

Install Docker

Mac:

“Docker for Mac” can be downloaded from: https://docs.docker.com/docker-for-mac/install/

"Docker for Mac" contains both Docker and Docker-compose

Ubuntu:

  • Docker:
sudo apt-get update
sudo apt-get install -y curl
sudo su -c 'curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -'
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
sudo apt-get -y update
sudo sudo apt-get install -y docker-ce
sudo update-rc.d docker enable
sudo groupadd docker
sudo gpasswd -a ${USER} docker
echo '{"storage-driver": "devicemapper"}' | sudo tee /etc/docker/daemon.json
sudo systemctl restart docker
sudo chown ${USER}:${USER} /var/run/docker.sock 
  • Docker-compose:
sudo curl -L -o /usr/local/bin/docker-compose $(curl -s https://api.github.com/repos/docker/compose/releases/latest | grep 'browser_' | cut -d\" -f4 | grep Linux | grep -v sha256)
sudo chmod +x /usr/local/bin/docker-compose
  • Make:
sudo apt-get install -y make

Setup

  1. Get the project from git (git clone https://github.com/UNIwise/backend-assignment.git) or download the zip file
  2. Navigate into the src foler and run: make build
  3. Open http://localhost/car this is where the assignment starts. Enjoy :)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published