- Docker locally.
- Git installed locally.
- PHP installed locally.
- Composer installed locally.
- Before starting, you should ensure that no other web servers or databases are running on your local computer.
- Clone the repository locally with
git clone git@github.com:JesusGarciaValadez/cyber-duck.git
. - Accessing to the repository with
cd cyber-duck
; - Copy the
.env.example
file as.env
and.env.testing
files. - Replace the following values in the
.env
file:
APP_NAME=
APP_URL=
...
DB_DATABASE=
DB_USERNAME=
DB_PASSWORD=
- For the
APP_URL
you can use thehttp://localhost
. - For the
.env.testing
file, you can leave the current values if you want. - You can use wherever values do you want to use for the database setup.
- Install the composer dependencies with
composer install
; - Run the command
php artisan sail:install
to publish the necessary for Docker to run. - Create the Docker container using
./vendor/bin/sail up -d
for the detached mode. - This will create the container using some environment variables of your
.env
file.
Once the container was created and running, you have to run the following commands:
./vendor/bin/sail artisan key:generate;
./vendor/bin/sail artisan migrate:fresh;
./vendor/bin/sail artisan migrate:fresh --env=testing;
You can run the following command ./vendor/bin/sail test
.
You can access the database using 127.0.0.1
as host
and the same values for the DB_USERNAME
, DB_PASSWORD
, and DB_USERNAME
stored in your .env
file.
You have to set up a link to the storage to make logos public. Just run the following command:
./vendor/bin/sail art storage:link
You can stop the containers using ./vendor/bin/sail down
.
You need to recreate the container running docker-compose build
, or stop the containers and images, deletep them, and run ./vendor/bin/sail up -d
to download the images again and rebuild them.
You can login enter to 'Login' using admin@admin.com
as username and password
as password. If you logged successfully, you can see the Dashboard
where you can acces to either Companies
section or the Employees
section.
You can see the result of the app deployed to production