As the centralized data store for the Sinai Manuscripts Digital Library website, the Portal will house records for all Sinai-related data and provide open-access data for research.
- Install Docker Desktop
- Clone this repository:
git clone [email protected]:UCLALibrary/sinai_portal.git
- Change into the project directory:
cd sinai_portal
- Copy
.env.example
to.env
and update it with application-specific configuration variables. - Run the following command to install Laravel Sail:
docker run --rm \ -u "$(id -u):$(id -g)" \ -v "$(pwd):/var/www/html" \ -w /var/www/html \ laravelsail/php82-composer:latest \ composer install --ignore-platform-reqs
- Start the application using Laravel Sail:
sail up
-
Note: If you do not have one already, setup an alias in your shell configuration file:
alias sail='[ -f sail ] && sh sail || sh vendor/bin/sail'
. See Configuring A Shell Alias. -
Note: If you encounter database role errors (e.g. FATAL: role "sinai" does not exist), run
sail down --rmi all -v
to remove all images and volumes followed bysail up
.
-
- Run the database migrations using Laravel Sail:
sail artisan migrate
- Note: If you encounter database connection errors or password authentication errors (e.g. FATAL: password authentication failed for user "sail"), run
sail down --rmi all -v
to remove all images and volumes followed bysail up
before running the database migrations.
- Note: If you encounter database connection errors or password authentication errors (e.g. FATAL: password authentication failed for user "sail"), run
- Install dependencies with Composer using Laravel Sail:
sail composer install
- Install frontend dependencies using Laravel Sail:
sail npm install
- Go to http://localhost:8005 and verify that the application is running.
- Watch and live reload local changes to JavaScript and CSS assets:
sail npm run dev
- Build JavaScript and CSS asset bundle for production:
sail npm run build
- Note: This is not necessary for development but might be useful if you want to inspect the generated/compiled JavaScript and CSS output files. You will find them under
public/build/assets
. Thepublic/build
folder is git ignored, therefore the generated files do not show up in git when they are rebuilt.
- Note: This is not necessary for development but might be useful if you want to inspect the generated/compiled JavaScript and CSS output files. You will find them under
sail npm <command>
- e.g.
sail npm install
- e.g.
sail artisan <command>
- e.g.
sail artisan migrate
- e.g.
sail composer <command>
- e.g.
sail composer install
- e.g.
- To test sending and receiving mails from the application locally, go to http://localhost:8028.
- For your changes in
docker-compose.yml
to take effect, runsail up --build
.