You've already forked joplin
							
							
				mirror of
				https://github.com/laurent22/joplin.git
				synced 2025-10-31 00:07:48 +02:00 
			
		
		
		
	Tools: Switch from "docker-compose" to "docker compose"
This commit is contained in:
		
							
								
								
									
										2
									
								
								.github/scripts/run_ci.sh
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.github/scripts/run_ci.sh
									
									
									
									
										vendored
									
									
								
							| @@ -90,7 +90,7 @@ if [ "$RUN_TESTS" == "1" ]; then | ||||
| 	# On Linux, we run the Joplin Server tests using PostgreSQL | ||||
| 	if [ "$IS_LINUX" == "1" ]; then | ||||
| 		echo "Running Joplin Server tests using PostgreSQL..." | ||||
| 		sudo docker-compose --file docker-compose.db-dev.yml up -d | ||||
| 		sudo docker compose --file docker-compose.db-dev.yml up -d | ||||
| 		cmdResult=$? | ||||
| 		if [ $cmdResult -ne 0 ]; then | ||||
| 			exit $cmdResult | ||||
|   | ||||
| @@ -5,7 +5,7 @@ | ||||
| // | ||||
| // To get it working: | ||||
| // | ||||
| // - Run the Postgres database -- `sudo docker-compose --file docker-compose.db-dev.yml up` | ||||
| // - Run the Postgres database -- `sudo docker compose --file docker-compose.db-dev.yml up` | ||||
| // - Update the DB parameters in ~/joplin-credentials/server.env to use the dev | ||||
| //   database | ||||
| // - Run the server - `JOPLIN_IS_TESTING=1 yarn start-dev` | ||||
|   | ||||
| @@ -30,7 +30,7 @@ The following tags are available: | ||||
|  | ||||
| ## Setup the database | ||||
|  | ||||
| You can setup the container to either use an existing PostgreSQL server, or connect it to a new database using docker-compose. | ||||
| You can setup the container to either use an existing PostgreSQL server, or connect it to a new database using `docker compose`. | ||||
|  | ||||
| ### Using an existing PostgreSQL server | ||||
|  | ||||
| @@ -56,7 +56,7 @@ POSTGRES_CONNECTION_STRING=postgresql://username:password@your_joplin_postgres_s | ||||
|  | ||||
| Ensure that the provided database and user exist as Joplin Server will not create them. When running on macOS or Windows through Docker Desktop, a mapping of localhost is made automatically. On Linux, you can add `--net=host --add-host=host.docker.internal:127.0.0.1` to the `docker run` command line to make the mapping happen. Any other `POSTGRES_HOST` than localhost or 127.0.0.1 should work as expected without further action. | ||||
|  | ||||
| ### Using docker-compose | ||||
| ### Using `docker compose` | ||||
|  | ||||
| 1. Using the [sample docker-compose file](https://raw.githubusercontent.com/laurent22/joplin/dev/docker-compose.server.yml), create a docker compose file in the location of your Docker configuration files. Example: /home/[user]/docker/docker-compose.yml | ||||
| 2. Update the fields in the docker-compose file as seen in the sample file. | ||||
| @@ -152,8 +152,8 @@ Checking the log can be done the standard Docker way: | ||||
| # With Docker: | ||||
| docker logs --follow CONTAINER | ||||
|  | ||||
| # With docker-compose: | ||||
| docker-compose --file docker-compose.server.yml logs | ||||
| # With `docker compose`: | ||||
| docker compose --file docker-compose.server.yml logs | ||||
| ``` | ||||
|  | ||||
| # Setup for development | ||||
| @@ -166,7 +166,7 @@ By default the server supports SQLite for development, so nothing needs to be se | ||||
|  | ||||
| ### PostgreSQL | ||||
|  | ||||
| To use Postgres, from the monorepo root, run `docker-compose --file docker-compose.server-dev.yml up`, which will start the PostgreSQL database. | ||||
| To use Postgres, from the monorepo root, run `docker compose --file docker-compose.server-dev.yml up`, which will start the PostgreSQL database. | ||||
|  | ||||
| ## Starting the server | ||||
|  | ||||
|   | ||||
| @@ -44,7 +44,7 @@ const defaultEnvVariables: Record<Env, any> = { | ||||
| 	dev: { | ||||
| 		// To test with the Postgres database, uncomment DB_CLIENT below and | ||||
| 		// comment out SQLITE_DATABASE. Then start the Postgres server using | ||||
| 		// `docker-compose --file docker-compose.db-dev.yml up` | ||||
| 		// `docker compose --file docker-compose.db-dev.yml up` | ||||
|  | ||||
| 		// DB_CLIENT: 'pg', | ||||
| 		SQLITE_DATABASE: `${sqliteDefaultDir}/db-dev.sqlite`, | ||||
|   | ||||
		Reference in New Issue
	
	Block a user