Closed elhmn closed 3 years ago
Got an error when starting error.txt
Got an error when starting error.txt
@DipandaAser on a PR/issue comment, please make sure to paste directly the error here not, sharing a link for a file... for security reason and for cleaning... cuz when i click on error.txt, my browser download the file.... and that can be a malware designed as a TEXT file.... who knows 😆 🙏🏾
aser@DESKTOP-TTIDH3N:/backend$ make start-postgres
docker-compose up start-postgres
Creating backend_postgres_1 ... done
Recreating backend_start-postgres_1 ... done
Attaching to backend_start-postgres_1
start-postgres_1 | /usr/bin/env: 'bash\r': No such file or directory
backend_start-postgres_1 exited with code 127
docker-compose logs -f
Attaching to backend_start-postgres_1, backend_postgres_1
start-postgres_1 | /usr/bin/env: 'bash\r': No such file or directory
postgres_1 | The files belonging to this database system will be owned by user "postgres".
postgres_1 | This user must also own the server process.
postgres_1 |
postgres_1 | The database cluster will be initialized with locale "en_US.utf8".
postgres_1 | The default database encoding has accordingly been set to "UTF8".
postgres_1 | The default text search configuration will be set to "english".
postgres_1 |
postgres_1 | Data page checksums are disabled.
postgres_1 |
postgres_1 | fixing permissions on existing directory /var/lib/postgresql/data ... ok
postgres_1 | creating subdirectories ... ok
postgres_1 | selecting dynamic shared memory implementation ... posix
postgres_1 | selecting default max_connections ... 100
postgres_1 | selecting default shared_buffers ... 128MB
postgres_1 | selecting default time zone ... Etc/UTC
postgres_1 | creating configuration files ... ok
postgres_1 | running bootstrap script ... ok
postgres_1 | performing post-bootstrap initialization ... ok
backend_start-postgres_1 exited with code 127
postgres_1 | syncing data to disk ... ok
postgres_1 |
postgres_1 | initdb: warning: enabling "trust" authentication for local connections
postgres_1 | You can change this by editing pg_hba.conf or using the option -A, or
postgres_1 | --auth-local and --auth-host, the next time you run initdb.
postgres_1 |
postgres_1 | Success. You can now start the database server using:
postgres_1 |
postgres_1 | pg_ctl -D /var/lib/postgresql/data -l logfile start
postgres_1 |
postgres_1 | waiting for server to start....2021-09-15 21:22:35.346 UTC [49] LOG: starting PostgreSQL 13.4 (Debian 13.4-1.pgdg100+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 8.3.0-6) 8.3.0, 64-bit
postgres_1 | 2021-09-15 21:22:35.440 UTC [49] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
postgres_1 | 2021-09-15 21:22:35.772 UTC [50] LOG: database system was shut down at 2021-09-15 21:22:19 UTC
postgres_1 | 2021-09-15 21:22:35.875 UTC [49] LOG: database system is ready to accept connections
postgres_1 | done
postgres_1 | server started
postgres_1 | CREATE DATABASE
postgres_1 |
postgres_1 |
postgres_1 | /usr/local/bin/docker-entrypoint.sh: ignoring /docker-entrypoint-initdb.d/*
postgres_1 |
postgres_1 | 2021-09-15 21:22:43.226 UTC [49] LOG: received fast shutdown request
postgres_1 | waiting for server to shut down....2021-09-15 21:22:43.313 UTC [49] LOG: aborting any active transactions
postgres_1 | 2021-09-15 21:22:43.316 UTC [49] LOG: background worker "logical replication launcher" (PID 56) exited with exit code 1
postgres_1 | 2021-09-15 21:22:43.316 UTC [51] LOG: shutting down
postgres_1 | 2021-09-15 21:22:43.824 UTC [49] LOG: database system is shut down
postgres_1 | done
postgres_1 | server stopped
postgres_1 |
postgres_1 | PostgreSQL init process complete; ready for start up.
postgres_1 |
postgres_1 | 2021-09-15 21:22:44.062 UTC [1] LOG: starting PostgreSQL 13.4 (Debian 13.4-1.pgdg100+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 8.3.0-6) 8.3.0, 64-bit
postgres_1 | 2021-09-15 21:22:44.062 UTC [1] LOG: listening on IPv4 address "0.0.0.0", port 5432
postgres_1 | 2021-09-15 21:22:44.062 UTC [1] LOG: listening on IPv6 address "::", port 5432
postgres_1 | 2021-09-15 21:22:44.274 UTC [1] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
postgres_1 | 2021-09-15 21:22:44.501 UTC [77] LOG: database system was shut down at 2021-09-15 21:22:43 UTC
postgres_1 | 2021-09-15 21:22:44.621 UTC [1] LOG: database system is ready to accept connections
This pull request implement development environment
Why ? We want developers to easily run the api with its dependency
How ? We have added a
setup-postgres
service that depends onpostgres
in thedocker-compose
This service will start postgres, initialise and populate the db with some fixture data.Steps to verify: Run
make start-postgres
, thencurl -H "Tenant: 1" localhost:9999/api/articles
. Once it returns a 200 with some data shut it down withmake stop-postgres