-
Notifications
You must be signed in to change notification settings - Fork 0
adding running locally documentation #7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Docker | ||
We are running the application within containers. Using Docker (or podman). | ||
Information about using Docker is widly spread on the internet. We only have some basic information mentioned here. | ||
Mainly to help the creating of images on the local machine. Mostly for testing purposes. | ||
|
||
## Used commands | ||
|
||
### WEB | ||
cd <main-folder>/olm-web | ||
docker build --rm -t phummelen/olm-web:latest -f deployment/web-dev.dockerfile . | ||
|
||
docker run --rm -it -p 9000:9000 phummelen/olm-web:latest | ||
|
||
### DOCS | ||
cd <main-folder>/olm-documentation | ||
docker build --rm -t phummelen/olm-docs:latest -f deploy/build/dockerfile . | ||
|
||
### MTA | ||
cd <main-folder>/olm-deploy | ||
docker build --rm -t phummelen/olm-mta:latest -f mta/Dockerfile . |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Version Control | ||
|
||
We change our code on a regular basis. To have good code, we use version control on [GitHub](https://github.com/). | ||
|
||
We have different repositories where our code resides. For different purposes and different update cadences. | ||
|
||
For the use of Git, there are lots of tutorials. For now, it's not written out here. | ||
*Maybe one of the other team members will add his (or her) experiences here* |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Introduction | ||
|
||
This software is opensource. That mean you can use, change, fork or whatever other something is convenient. | ||
We still love if you participate in the community, to get better software, better data or spreading the same message all over the world. | ||
|
||
To be able to assist the core team in the development, we have tried to have the software easy to use on the local machine. | ||
|
||
This section is created to help you start up locally and help the development. If you have any question please reach out to the development team for help. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
# Running locally | ||
|
||
If you want to run the environment locally, that's possible! | ||
You have to download the main repo(s) where a `docker-compose` file is in. | ||
Also you have to have *Docker* (or podman) installed on you machine. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. you --> your |
||
|
||
With those two pre-requisites you can start the containers locally. | ||
Be aware, for some features you need `keys`, which are not *free to use* from the community. If needed, reach out to the core team for help. | ||
|
||
After first startup, we have to do some manual actions. In the future we gonna try to get these steps within setup-containers. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. gonna --> going to |
||
|
||
## Start | ||
So, these are the (commandline) steps to start and initialize the environment | ||
|
||
1. To start: `docker-compose up -d` (or `docker-compose start` if just stopped) | ||
2. To enter the container (initialize): `docker exec -it olm-web /bin/bash` | ||
3. To load dummy data (initialize): `php artisan migrate:fresh --seed` | ||
4. Log out or the container using (after initialisation) `ctrl-d` or `exit` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. initialisation --> initialization |
||
5. Go to the local site: [direct](http://localhost:8000/) or via [proxy](http://localhost:8080) | ||
|
||
NB: If you have initialized the database, you can skip the *initialize* steps. Step one is mandatory. | ||
|
||
You should see the basic site now. Several function will work, several will not work. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. function --> functions |
||
To log in, there are two accounts: | ||
|
||
|User|Password| | ||
|----|--------| | ||
|[email protected]|password| | ||
|[email protected]|password| | ||
|
||
## Stop | ||
To stop the environment there are three options: | ||
|
||
- stop only: `docker-compose stop` | ||
- bring down: `docker-compose down` | ||
- bring down and remove: `docker-compose down -v` | ||
|
||
I'm mostly using the middle one. For me that's the best, because I do a lot of docker stuff on my machine. | ||
Also, using this command will always use the latest version of the (newly pulled) images. | ||
|
||
## Update images | ||
|
||
To refresh the local images with the ones from the Docker registry, the main command is `docker pull [docker_image]`. | ||
We currently have three own created images, so we have three commands to be given: | ||
|
||
`docker pull phummelen/olm-mta` | ||
`docker pull phummelen/olm-docs` | ||
`docker pull phummelen/olm-web` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
widly --> widely