Skip to content

Commit

Permalink
Add & updates things for easy setup
Browse files Browse the repository at this point in the history
  • Loading branch information
emincanozcan committed Dec 12, 2021
1 parent eeb2c16 commit c693b45
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 11 deletions.
18 changes: 9 additions & 9 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
APP_NAME=Laravel
APP_NAME=FooBar
APP_ENV=local
APP_KEY=
APP_DEBUG=true
APP_URL=http://localhost

SOCKET_ENDPOINT=http://localhost
SOCKET_ENDPOINT=http://localhost:4000

LOG_CHANNEL=stack
LOG_DEPRECATIONS_CHANNEL=null
LOG_LEVEL=debug

DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_CONNECTION=pgsql
DB_HOST=pgsql
DB_PORT=5432
DB_DATABASE=new_app
DB_USERNAME=root
DB_PASSWORD=
DB_USERNAME=sail
DB_PASSWORD=password

BROADCAST_DRIVER=log
CACHE_DRIVER=file
FILESYSTEM_DRIVER=local
QUEUE_CONNECTION=sync
SESSION_DRIVER=database
SESSION_DRIVER=redis
SESSION_LIFETIME=120

MEMCACHED_HOST=127.0.0.1

REDIS_HOST=127.0.0.1
REDIS_HOST=redis
REDIS_PASSWORD=null
REDIS_PORT=6379
REDIS_PREFIX=
Expand Down
26 changes: 24 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,25 @@ This is how the idea of FooBar.Live was born. It emerged as an attempt to solve

FooBar.Tv is completely dockerized. It is possible to run the project without Docker, but it is not recommended because of the effort that it will take.

### Install With Docker
### Install With Docker - Automatic

There is a file in the project called [`setup.sh`](setup.sh), it is basically a shell script that runs the necessary commands for installation.

If you don't want to run a shell script directly, you can follow the steps at (#install-with-docker---manual)[Install With Docker - Manual].

```bash
# Clone this repository
$ git clone https://github.com/emincanozcan/foobar.live

# Go into the repository
$ cd foobar.live

# Run the script
$ chmox +x ./setup.sh && ./setup.sh
```


### Install With Docker - Manual

```bash
# Clone this repository
Expand All @@ -38,7 +56,7 @@ $ cd foobar.live
$ cp .env.example .env

# Install PHP dependencies using a docker container
$ docker run --rm --interactive --tty volume $PWD:/app composer install
$ docker run --rm --interactive --tty --volume $PWD:/app composer install

# Run the containers
$ ./vendor/bin/sail up -d
Expand Down Expand Up @@ -77,3 +95,7 @@ If you have interest, you can take a look [FFmpeg Streaming Guide](https://trac.

$ ffmpeg -re -i videofilepath.mp4 -vcodec libx264 -vprofile baseline -g 30 -acodec aac -strict -2 -f flv rtmp://localhost:1935/stream_receiver/$STREAM_KEY
```

## License

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.
9 changes: 9 additions & 0 deletions setup.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/usr/bin/env bash

cp .env.example .env

docker run --rm --interactive --tty --volume $PWD:/app composer install

./vendor/bin/sail up -d

./vendor/bin/sail artisan key:generate && ./vendor/bin/sail artisan storage:link && ./vendor/bin/sail artisan migrate --seed

0 comments on commit c693b45

Please sign in to comment.