Add files via upload

This commit is contained in:
Kelvin F. Alfaro
2022-07-03 11:57:51 -05:00
committed by GitHub
parent 9e6cc5d7f8
commit c283a92614
5 changed files with 327 additions and 313 deletions

View File

@@ -1,46 +1,46 @@
FROM node:14 as builder FROM node:14 as builder
WORKDIR /calcom WORKDIR /calcom
ARG NEXT_PUBLIC_WEBAPP_URL=http://localhost:3000 ARG NEXT_PUBLIC_WEBAPP_URL=http://localhost:3000
ARG NEXT_PUBLIC_APP_URL ARG NEXT_PUBLIC_APP_URL
ARG NEXT_PUBLIC_LICENSE_CONSENT ARG NEXT_PUBLIC_LICENSE_CONSENT
ARG CALCOM_TELEMETRY_DISABLED ARG CALCOM_TELEMETRY_DISABLED
ARG DATABASE_URL ARG DATABASE_URL
ARG NEXTAUTH_SECRET=secret ARG NEXTAUTH_SECRET=secret
ARG CALENDSO_ENCRYPTION_KEY=secret ARG CALENDSO_ENCRYPTION_KEY=secret
ENV NEXT_PUBLIC_WEBAPP_URL=$NEXT_PUBLIC_WEBAPP_URL \ ENV NEXT_PUBLIC_WEBAPP_URL=$NEXT_PUBLIC_WEBAPP_URL \
NEXT_PUBLIC_APP_URL=$NEXT_PUBLIC_APP_URL \ NEXT_PUBLIC_APP_URL=$NEXT_PUBLIC_APP_URL \
NEXT_PUBLIC_LICENSE_CONSENT=$NEXT_PUBLIC_LICENSE_CONSENT \ NEXT_PUBLIC_LICENSE_CONSENT=$NEXT_PUBLIC_LICENSE_CONSENT \
CALCOM_TELEMETRY_DISABLED=$CALCOM_TELEMETRY_DISABLED \ CALCOM_TELEMETRY_DISABLED=$CALCOM_TELEMETRY_DISABLED \
DATABASE_URL=$DATABASE_URL \ DATABASE_URL=$DATABASE_URL \
NEXTAUTH_SECRET=${NEXTAUTH_SECRET} \ NEXTAUTH_SECRET=${NEXTAUTH_SECRET} \
CALENDSO_ENCRYPTION_KEY=${CALENDSO_ENCRYPTION_KEY} CALENDSO_ENCRYPTION_KEY=${CALENDSO_ENCRYPTION_KEY}
COPY calcom/package.json calcom/yarn.lock calcom/turbo.json ./ COPY calcom/package.json calcom/yarn.lock calcom/turbo.json ./
COPY calcom/apps/web ./apps/web COPY calcom/apps/web ./apps/web
COPY calcom/packages ./packages COPY calcom/packages ./packages
RUN yarn install --frozen-lockfile RUN yarn install --frozen-lockfile
RUN yarn build RUN yarn build
FROM node:14 as runner FROM node:14 as runner
WORKDIR /calcom WORKDIR /calcom
ENV NODE_ENV production ENV NODE_ENV production
RUN apt-get update && \ RUN apt-get update && \
apt-get -y install netcat && \ apt-get -y install netcat && \
rm -rf /var/lib/apt/lists/* && \ rm -rf /var/lib/apt/lists/* && \
npm install --global prisma npm install --global prisma
COPY calcom/package.json calcom/yarn.lock calcom/turbo.json ./ COPY calcom/package.json calcom/yarn.lock calcom/turbo.json ./
COPY --from=builder /calcom/node_modules ./node_modules COPY --from=builder /calcom/node_modules ./node_modules
COPY --from=builder /calcom/packages ./packages COPY --from=builder /calcom/packages ./packages
COPY --from=builder /calcom/apps/web ./apps/web COPY --from=builder /calcom/apps/web ./apps/web
COPY --from=builder /calcom/packages/prisma/schema.prisma ./prisma/schema.prisma COPY --from=builder /calcom/packages/prisma/schema.prisma ./prisma/schema.prisma
COPY scripts scripts COPY scripts scripts
EXPOSE 3000 EXPOSE 3000
CMD ["/calcom/scripts/start.sh"] CMD ["/calcom/scripts/start.sh"]

38
LICENSE
View File

@@ -1,19 +1,19 @@
Copyright (c) 2021 Calendso Copyright (c) 2021 Calendso
Permission is hereby granted, free of charge, to any person obtaining a copy Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions: furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software. copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
OR OTHER DEALINGS IN THE SOFTWARE. OR OTHER DEALINGS IN THE SOFTWARE.

296
README.md
View File

@@ -1,148 +1,148 @@
<!-- PROJECT LOGO --> <!-- PROJECT LOGO -->
<div align="right"> <div align="right">
<a href="https://github.com/calcom/cal.com"> <a href="https://github.com/calcom/cal.com">
<img src="https://cal.com/logo.svg" alt="Logo" width="160" height="65"> <img src="https://cal.com/logo.svg" alt="Logo" width="160" height="65">
</a><br/> </a><br/>
<a href="https://cal.com">Website</a> <a href="https://cal.com">Website</a>
· ·
<a href="https://github.com/calcom/docker/issues">Community Support</a> <a href="https://github.com/calcom/docker/issues">Community Support</a>
</div> </div>
# Docker # Docker
NOTE: DockerHub organization has not yet been renamed. NOTE: DockerHub organization has not yet been renamed.
This image can be found on DockerHub at [https://hub.docker.com/r/calendso/calendso](https://hub.docker.com/r/calendso/calendso) This image can be found on DockerHub at [https://hub.docker.com/r/calendso/calendso](https://hub.docker.com/r/calendso/calendso)
The Docker configuration for Cal.com is an effort powered by people within the community. Cal.com, Inc. does not yet provide official support for Docker, but we will accept fixes and documentation at this time. Use at your own risk. The Docker configuration for Cal.com is an effort powered by people within the community. Cal.com, Inc. does not yet provide official support for Docker, but we will accept fixes and documentation at this time. Use at your own risk.
## Important Notes ## Important Notes
This Docker Image is managed by the Cal.com Community. Support for this image can be found via the repository, located at [https://github.com/calcom/docker](https://github.com/calcom/docker) This Docker Image is managed by the Cal.com Community. Support for this image can be found via the repository, located at [https://github.com/calcom/docker](https://github.com/calcom/docker)
Currently, this image is intended for local development/evaluation use only, as there are specific requirements for providing environmental variables at build-time in order to specify a non-localhost BASE_URL. (this is due to the nature of the static site compilation, which embeds the variable values). The ability to update these variables at runtime is in-progress and will be available in the future. Currently, this image is intended for local development/evaluation use only, as there are specific requirements for providing environmental variables at build-time in order to specify a non-localhost BASE_URL. (this is due to the nature of the static site compilation, which embeds the variable values). The ability to update these variables at runtime is in-progress and will be available in the future.
For Production, for the time being, please checkout the repository and build/push your own image privately. For Production, for the time being, please checkout the repository and build/push your own image privately.
## Requirements ## Requirements
Make sure you have `docker` & `docker compose` installed on the server / system. Both are installed by most docker utilities, including Docker Desktop and Rancher Desktop. Make sure you have `docker` & `docker compose` installed on the server / system. Both are installed by most docker utilities, including Docker Desktop and Rancher Desktop.
Note: `docker compose` without the hyphen is now the primary method of using docker-compose, per the Docker documentation. Note: `docker compose` without the hyphen is now the primary method of using docker-compose, per the Docker documentation.
## Getting Started ## Getting Started
1. Clone calcom-docker 1. Clone calcom-docker
```bash ```bash
git clone https://github.com/calcom/docker.git calcom-docker git clone https://github.com/calcom/docker.git calcom-docker
``` ```
2. Change into the directory 2. Change into the directory
```bash ```bash
cd calcom-docker cd calcom-docker
``` ```
3. Update the calcom submodule. 3. Update the calcom submodule.
```bash ```bash
git submodule update --remote --init git submodule update --remote --init
``` ```
Note: DO NOT use recursive submodule update, otherwise you will receive a git authentication error. Note: DO NOT use recursive submodule update, otherwise you will receive a git authentication error.
4. Rename `.env.example` to `.env` and then update `.env` 4. Rename `.env.example` to `.env` and then update `.env`
5. Build the Cal.com docker image: 5. Build the Cal.com docker image:
Note: Due to application configuration requirements, an available database is currently required during the build process. Note: Due to application configuration requirements, an available database is currently required during the build process.
a) If hosting elsewhere, configure the `DATABASE_URL` in the .env file, and skip the next step a) If hosting elsewhere, configure the `DATABASE_URL` in the .env file, and skip the next step
b) If a local or temporary database is required, start a local database via docker compose. b) If a local or temporary database is required, start a local database via docker compose.
```bash ```bash
docker compose up -d database docker compose up -d database
``` ```
6. Build Cal.com via docker compose (DOCKER_BUILDKIT=0 must be provided to allow a network bridge to be used at build time. This requirement will be removed in the future) 6. Build Cal.com via docker compose (DOCKER_BUILDKIT=0 must be provided to allow a network bridge to be used at build time. This requirement will be removed in the future)
```bash ```bash
DOCKER_BUILDKIT=0 docker compose build calcom DOCKER_BUILDKIT=0 docker compose build calcom
``` ```
7. Start Cal.com via docker compose 7. Start Cal.com via docker compose
(Most basic users, and for First Run) To run the complete stack, which includes a local Postgres database, Cal.com web app, and Prisma Studio: (Most basic users, and for First Run) To run the complete stack, which includes a local Postgres database, Cal.com web app, and Prisma Studio:
```bash ```bash
docker compose up -d docker compose up -d
``` ```
To run Cal.com web app and Prisma Studio against a remote database, ensure that DATABASE_URL is configured for an available database and run: To run Cal.com web app and Prisma Studio against a remote database, ensure that DATABASE_URL is configured for an available database and run:
```bash ```bash
docker compose up -d calcom studio docker compose up -d calcom studio
``` ```
To run only the Cal.com web app, ensure that DATABASE_URL is configured for an available database and run: To run only the Cal.com web app, ensure that DATABASE_URL is configured for an available database and run:
```bash ```bash
docker compose up -d calcom docker compose up -d calcom
``` ```
**Note: to run in attached mode for debugging, remove `-d` from your desired run command.** **Note: to run in attached mode for debugging, remove `-d` from your desired run command.**
8. (First Run) Open a browser to [http://localhost:5555](http://localhost:5555) to look at or modify the database content. 8. (First Run) Open a browser to [http://localhost:5555](http://localhost:5555) to look at or modify the database content.
a. Click on the `User` model to add a new user record. a. Click on the `User` model to add a new user record.
b. Fill out the fields (remembering to encrypt your password with [BCrypt](https://bcrypt-generator.com/)) and click `Save 1 Record` to create your first user. b. Fill out the fields (remembering to encrypt your password with [BCrypt](https://bcrypt-generator.com/)) and click `Save 1 Record` to create your first user.
9. Open a browser to [http://localhost:3000](http://localhost:3000) (or your appropriately configured NEXT_PUBLIC_WEBAPP_URL) and login with your just created, first user. 9. Open a browser to [http://localhost:3000](http://localhost:3000) (or your appropriately configured NEXT_PUBLIC_WEBAPP_URL) and login with your just created, first user.
## Configuration ## Configuration
### Build-time variables ### Build-time variables
These variables must be provided at the time of the docker build, and can be provided by updating the .env file. Currently, if you require changes to these variables, you must follow the instructions to build and publish your own image. These variables must be provided at the time of the docker build, and can be provided by updating the .env file. Currently, if you require changes to these variables, you must follow the instructions to build and publish your own image.
Updating these variables is not required for evaluation, but is required for running in production. Instructions for generating variables can be found in the [cal.com instructions](https://github.com/calcom/cal.com) Updating these variables is not required for evaluation, but is required for running in production. Instructions for generating variables can be found in the [cal.com instructions](https://github.com/calcom/cal.com)
| Variable | Description | Required | Default | | Variable | Description | Required | Default |
| --- | --- | --- | --- | | --- | --- | --- | --- |
| NEXT_PUBLIC_WEBAPP_URL | Base URL injected into static files | required | `http://localhost:3000` | | NEXT_PUBLIC_WEBAPP_URL | Base URL injected into static files | required | `http://localhost:3000` |
| NEXT_PUBLIC_LICENSE_CONSENT | license consent - true/false | | | | NEXT_PUBLIC_LICENSE_CONSENT | license consent - true/false | | |
| CALCOM_TELEMETRY_DISABLED | Allow cal.com to collect anonymous usage data (set to `1` to disable) | | | | CALCOM_TELEMETRY_DISABLED | Allow cal.com to collect anonymous usage data (set to `1` to disable) | | |
| DATABASE_URL | database url with credentials | required | `postgresql://unicorn_user:magical_password@database:5432/calendso` | | DATABASE_URL | database url with credentials | required | `postgresql://unicorn_user:magical_password@database:5432/calendso` |
| NEXTAUTH_SECRET | Cookie encryption key | required | `secret` | | NEXTAUTH_SECRET | Cookie encryption key | required | `secret` |
| CALENDSO_ENCRYPTION_KEY | Authentication encryption key | required | `secret` | | CALENDSO_ENCRYPTION_KEY | Authentication encryption key | required | `secret` |
### Important Run-time variables ### Important Run-time variables
These variables must also be provided at runtime These variables must also be provided at runtime
| Variable | Description | Required | Default | | Variable | Description | Required | Default |
| --- | --- | --- | --- | | --- | --- | --- | --- |
| CALCOM_LICENSE_KEY | Enterprise License Key | | | | CALCOM_LICENSE_KEY | Enterprise License Key | | |
| NEXTAUTH_SECRET | must match build variable | required | `secret` | | NEXTAUTH_SECRET | must match build variable | required | `secret` |
| CALENDSO_ENCRYPTION_KEY | must match build variable | required | `secret` | | CALENDSO_ENCRYPTION_KEY | must match build variable | required | `secret` |
| DATABASE_URL | database url with credentials | required | `postgresql://unicorn_user:magical_password@database:5432/calendso` | | DATABASE_URL | database url with credentials | required | `postgresql://unicorn_user:magical_password@database:5432/calendso` |
## Git Submodules ## Git Submodules
This repository uses a git submodule. This repository uses a git submodule.
To update the calcom submodule, use the following command: To update the calcom submodule, use the following command:
```bash ```bash
git submodule update --remote --init git submodule update --remote --init
``` ```
For more advanced usage, please refer to the git documentation: [https://git-scm.com/book/en/v2/Git-Tools-Submodules](https://git-scm.com/book/en/v2/Git-Tools-Submodules) For more advanced usage, please refer to the git documentation: [https://git-scm.com/book/en/v2/Git-Tools-Submodules](https://git-scm.com/book/en/v2/Git-Tools-Submodules)
## Troubleshooting ## Troubleshooting
* SSL edge termination: If running behind a load balancer which handles SSL certificates, you will need to add the environmental variable `NODE_TLS_REJECT_UNAUTHORIZED=0` to prevent requests from being rejected. Only do this if you know what you are doing and trust the services/load-balancers directing traffic to your service. * SSL edge termination: If running behind a load balancer which handles SSL certificates, you will need to add the environmental variable `NODE_TLS_REJECT_UNAUTHORIZED=0` to prevent requests from being rejected. Only do this if you know what you are doing and trust the services/load-balancers directing traffic to your service.
* Failed to commit changes: Invalid 'prisma.user.create()': Certain versions may have trouble creating a user if the field `metadata` is empty. Using an empty json object `{}` as the field value should resolve this issue. Also, the `id` field will autoincrement, so you may also try leaving the value of `id` as empty. * Failed to commit changes: Invalid 'prisma.user.create()': Certain versions may have trouble creating a user if the field `metadata` is empty. Using an empty json object `{}` as the field value should resolve this issue. Also, the `id` field will autoincrement, so you may also try leaving the value of `id` as empty.

View File

@@ -1,38 +1,38 @@
# Security # Security
Contact: security@cal.com Contact: security@cal.com
Based on [https://supabase.com/.well-known/security.txt](https://supabase.com/.well-known/security.txt) Based on [https://supabase.com/.well-known/security.txt](https://supabase.com/.well-known/security.txt)
At Cal.com, we consider the security of our systems a top priority. But no matter how much effort we put into system security, there can still be vulnerabilities present. At Cal.com, we consider the security of our systems a top priority. But no matter how much effort we put into system security, there can still be vulnerabilities present.
If you discover a vulnerability, we would like to know about it so we can take steps to address it as quickly as possible. We would like to ask you to help us better protect our clients and our systems. If you discover a vulnerability, we would like to know about it so we can take steps to address it as quickly as possible. We would like to ask you to help us better protect our clients and our systems.
## Out of scope vulnerabilities: ## Out of scope vulnerabilities:
* Clickjacking on pages with no sensitive actions. * Clickjacking on pages with no sensitive actions.
* Unauthenticated/logout/login CSRF. * Unauthenticated/logout/login CSRF.
* Attacks requiring MITM or physical access to a user's device. * Attacks requiring MITM or physical access to a user's device.
* Any activity that could lead to the disruption of our service (DoS). * Any activity that could lead to the disruption of our service (DoS).
* Content spoofing and text injection issues without showing an attack vector/without being able to modify HTML/CSS. * Content spoofing and text injection issues without showing an attack vector/without being able to modify HTML/CSS.
* Email spoofing * Email spoofing
* Missing DNSSEC, CAA, CSP headers * Missing DNSSEC, CAA, CSP headers
* Lack of Secure or HTTP only flag on non-sensitive cookies * Lack of Secure or HTTP only flag on non-sensitive cookies
* Deadlinks * Deadlinks
## Please do the following: ## Please do the following:
* E-mail your findings to [security@cal.com](mailto:security@cal.com). * E-mail your findings to [security@cal.com](mailto:security@cal.com).
* Do not run automated scanners on our infrastructure or dashboard. If you wish to do this, contact us and we will set up a sandbox for you. * Do not run automated scanners on our infrastructure or dashboard. If you wish to do this, contact us and we will set up a sandbox for you.
* Do not take advantage of the vulnerability or problem you have discovered, for example by downloading more data than necessary to demonstrate the vulnerability or deleting or modifying other people's data, * Do not take advantage of the vulnerability or problem you have discovered, for example by downloading more data than necessary to demonstrate the vulnerability or deleting or modifying other people's data,
* Do not reveal the problem to others until it has been resolved, * Do not reveal the problem to others until it has been resolved,
* Do not use attacks on physical security, social engineering, distributed denial of service, spam or applications of third parties, * Do not use attacks on physical security, social engineering, distributed denial of service, spam or applications of third parties,
* Do provide sufficient information to reproduce the problem, so we will be able to resolve it as quickly as possible. Usually, the IP address or the URL of the affected system and a description of the vulnerability will be sufficient, but complex vulnerabilities may require further explanation. * Do provide sufficient information to reproduce the problem, so we will be able to resolve it as quickly as possible. Usually, the IP address or the URL of the affected system and a description of the vulnerability will be sufficient, but complex vulnerabilities may require further explanation.
## What we promise: ## What we promise:
* We will respond to your report within 3 business days with our evaluation of the report and an expected resolution date, * We will respond to your report within 3 business days with our evaluation of the report and an expected resolution date,
* If you have followed the instructions above, we will not take any legal action against you in regard to the report, * If you have followed the instructions above, we will not take any legal action against you in regard to the report,
* We will handle your report with strict confidentiality, and not pass on your personal details to third parties without your permission, * We will handle your report with strict confidentiality, and not pass on your personal details to third parties without your permission,
* We will keep you informed of the progress towards resolving the problem, * We will keep you informed of the progress towards resolving the problem,
* In the public information concerning the problem reported, we will give your name as the discoverer of the problem (unless you desire otherwise), and * In the public information concerning the problem reported, we will give your name as the discoverer of the problem (unless you desire otherwise), and
* We strive to resolve all problems as quickly as possible, and we would like to play an active role in the ultimate publication on the problem after it is resolved. * We strive to resolve all problems as quickly as possible, and we would like to play an active role in the ultimate publication on the problem after it is resolved.

View File

@@ -1,62 +1,76 @@
# Use postgres/example user/password credentials # Use postgres/example user/password credentials; starts a postgres instance on port 5450 to use as a local db
version: '3.1' version: '3.9'
volumes: volumes:
database-data: database-data:
networks: networks:
stack: stack:
name: stack name: stack
external: false external: false
services: services:
database: database:
image: postgres image: postgres # profiles: ["withpostgres"] only starts when specifying this profile
restart: always container_name: calendso-db
volumes: restart: unless-stopped
- database-data:/var/lib/postgresql/data/ volumes:
env_file: .env - database-data:/var/lib/postgresql/data/
networks: env_file: .env
- stack networks:
- stack
calcom: - calendso-stack
build:
context: . calcom:
dockerfile: Dockerfile build:
args: context: .
- NEXT_PUBLIC_WEBAPP_URL=${NEXT_PUBLIC_WEBAPP_URL} dockerfile: Dockerfile
- NEXT_PUBLIC_LICENSE_CONSENT=${NEXT_PUBLIC_LICENSE_CONSENT} args:
- CALCOM_TELEMETRY_DISABLED=${CALCOM_TELEMETRY_DISABLED} - NEXT_PUBLIC_WEBAPP_URL=${NEXT_PUBLIC_WEBAPP_URL}
- NEXTAUTH_SECRET=${NEXTAUTH_SECRET} - NEXT_PUBLIC_LICENSE_CONSENT=${NEXT_PUBLIC_LICENSE_CONSENT}
- CALENDSO_ENCRYPTION_KEY=${CALENDSO_ENCRYPTION_KEY} - CALCOM_TELEMETRY_DISABLED=${CALCOM_TELEMETRY_DISABLED}
- DATABASE_URL=${DATABASE_URL} - NEXTAUTH_SECRET=${NEXTAUTH_SECRET}
network: stack - CALENDSO_ENCRYPTION_KEY=${CALENDSO_ENCRYPTION_KEY}
restart: always - DATABASE_URL=${DATABASE_URL}
networks: network: stack
- stack restart: always
ports: networks:
- 3000:3000 - stack
env_file: .env - calendso-stack
environment: ports:
- DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${DATABASE_HOST}/${POSTGRES_DB} - ${PORT-3000}:3000
depends_on: env_file: .env
- database environment:
- DATABASE_URL=${DATABASE_URL}
# Optional use of Prisma Studio. In production, comment out or remove the section below to prevent unwanted access to your database. - NODE_ENV=development
studio: - POSTGRES_PASSWORD = ""
image: calendso/calendso:latest - POSTGRES_HOST_AUTH_METHOD = trust
restart: always depends_on:
networks: - database # comment out when using non-docker database (=enabled "withpostgres" profile)
- stack volumes:
ports: - "./calendso:/app/"
- 5555:5555 - "./scripts:/app/scripts"
env_file: .env
environment: # Optional use of Prisma Studio. To use *with* Prisma Studio:
- DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${DATABASE_HOST}/${POSTGRES_DB} # docker-compose --profile withstudio up
depends_on: studio:
- database image: calendso/calendso:latest
command: container_name: calendso-studio
- npx restart: unless-stopped
- prisma profiles: ["withstudio"] # only starts when specifying this profile
- studio networks:
# END SECTION: Optional use of Prisma Studio. - stack
- calendso-stack
ports:
- 5555:5555
volumes:
db_data:
env_file: .env
environment:
- DATABASE_URL=${DATABASE_URL}
depends_on:
- database # comment out when using non-docker database (=enabled "withpostgres" profile)
command:
- npx
- prisma
- studio