Skip to content

capn-nepal/website-cms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CAPN Nepal CMS

Built with

React Vite Typescript

Getting started

Below are the steps to guide you through preparing your local enviroment for the CMS. Before diving into setup please look into the concept of Github Sub Modules, Docker Merge.

Prerequisites

To begin, ensure you have network access. Then, you'll need the following:

  1. Git
  2. Node.JS version >=18 / 20+
  3. Pnpm
  4. Alternatively, you can use Docker to build the application.

Local development (with docker)

Clone the repository using HTTPS, SSH, or Github CLI

git clone https://github.com/capn-nepal/website-cms.git #HTTPS
git clone git@github.com:capn-nepal/website-cms.git #SSH
gh repo clone capn-nepal/website-cms #Github CLI

Download the contents of backend(website-backend)

git submodule update --init --recursive

Update Environment variables

  • create .env file and add COMPOSE_FILE variable for the website-cms
touch .env
  • Copy env.example to .env and update the variables for the backend
cd backend
cp env.example .env

NOTE: The backend has a higher priority than the website-cms. You can add backend environment variables in the CMS, but you must create a .env file in the backend for them to work.

Build the docker image

docker compose build

Start the development server

docker compose up

Install the dependencies

docker compose exec react bash -c 'pnpm install'

Generate type

docker compose exec react bash -c 'pnpm generate:type'

Local development (without docker)

Same steps upto downloading the contents of backend

Update Enviroment variables

  • create .env file and add COMPOSE_FILE and other variable for the website-cms
touch .env

NOTE: Copy the env variables from the docker compose file in environment section

Install the dependencies

pnpm install

Generate type

pnpm generate:type

Start the development server

pnpm start

About

CMS repository of CAPN website

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors 2

  •  
  •