2024-06-22 22:07:47 +00:00
# frontend
2023-12-08 05:20:55 +00:00
2024-06-22 22:07:47 +00:00
This is a [vite ](https://vitejs.dev/ ) [react ](https://reactjs.org/ ) [nextjs ](https://nextjs.org/ ) project in a [yarn workspace ](https://yarnpkg.com/features/workspaces ).
2023-12-08 05:20:55 +00:00
2024-06-22 22:07:47 +00:00
## Getting Started
2023-12-08 05:20:55 +00:00
2024-06-22 22:07:47 +00:00
### Install dependencies
2023-12-08 05:20:55 +00:00
2024-06-22 22:07:47 +00:00
In the root of the project, run:
2023-12-08 05:20:55 +00:00
2024-06-22 22:07:47 +00:00
```zsh
yarn
```
### Build backend
```zsh
2024-06-24 19:00:45 +00:00
yarn build --ignore frontend
2024-06-22 22:07:47 +00:00
```
### Environment variables
#### Local
Copy the `.env.example` file to `.env` :
```zsh
cp .env.example .env
```
#### Staging environment variables
Change in [deployer/deploy-frontend.staging.sh ](/packages/deployer/deploy-frontend.staging.sh )
2023-12-08 05:20:55 +00:00
2024-06-22 22:07:47 +00:00
#### Production environment variables
2023-12-08 05:20:55 +00:00
2024-06-22 22:07:47 +00:00
Change in [deployer/deploy-frontend.sh ](/packages/deployer/deploy-frontend.sh )
### Run development server
```zsh
yarn dev
2024-04-11 21:40:22 +00:00
```
2023-12-08 05:20:55 +00:00
2024-06-22 22:07:47 +00:00
## Deployment
2024-06-25 05:08:38 +00:00
From the root of the project,
- check if the [gittea repository mirror ](https://git.vdb.to/cerc-io/snowballtools-base ) is up to date
2024-06-22 22:07:47 +00:00
### Staging
```zsh
cd packages/deployer & & ./deploy-frontend.staging.sh
```
### Production
```zsh
cd packages/deployer & & ./deploy-frontend.sh
```
### Deployment status
Check the status of the deployment [here ](https://webapp-deployer.apps.snowballtools.com )