-
Notifications
You must be signed in to change notification settings - Fork 0
Getting started
This guide will help you to set up your development environment so you can start development as soon as possible.
This guide is written for Arch Linux however should work fine on mac with some adjustments. Windows users have to install mentioned packages by manually searching for them online.
The code base is being run inside a docker container that contains all the packages. This is recommended because you will not trash your computer with a ton of programs.
pacman -Syu yay # update the system repositories and install AUR helper
yay -Syu github-desktop-bin git docker docker-compose postman-bin visual-studio-code-bin composer unzip # install packages
sudo usermod -aG docker $USER # A shell restart might be needed after this command.
git clone --recursive [email protected]:pavelskipenes/org.ntnu.svommer.git
cd org.ntnu.svommer
systemctl enable docker --now
composer update # remember to commit the change
docker-compose up
Look for a line like this: 2021-10-03 22:44:52+00:00 [Note] [Entrypoint]: GENERATED ROOT PASSWORD: 8o~bU=kZxQ"O47lBUz_9?=S3jCpgi2jD
Take note of this password and go to next session. Do not terminate the docker-compose
program just yet.
- Log into https://mysqladmin.it.ntnu.no/ using your credentials -> export -> go.
- Go to your web browser at 127.0.0.1:42069 and login using username
root
and password that was printed in the terminal window above. - Click on import and then import the downloaded file from previous step.
- Click on User accounts, add user
- Create user
svommer_web
with all permissions - Terminate the
docker-compose
program running in the terminal by pressingCtrl+C
assuming your username is pavelgs
and your server is login.stud.ntnu.no
scp -r [email protected]:svommer/translations/ ./translations/../
Now you're all set. You should see web site on https://127.0.0.1
. First time you enter the web site the browser will say that the sertificate is not verified. Ignore that because the docker image is signing the image during creation. You'll also get access to phpmyadmin on 127.0.0.1:42069
(HTTP only).
After you've set up the application you can start the application by running:
docker-compose up -d
and terminating it by pressing Ctrl+C
.