rails/.devcontainer/devcontainer.json
Rafael Mendonça França 451dec7968
Run postgresql using docker compose on devcontainer
This will make easier to make sure the service is running when the
development container is started.

Before after the first time the container was created, if it was
restarted you needed to run the boot.sh script manually to start the
service.
2023-08-05 02:47:42 +00:00

41 lines
1.1 KiB
JSON

// For format details, see https://aka.ms/devcontainer.json.
{
"name": "Rails project development",
"dockerComposeFile": "docker-compose.yml",
"service": "rails",
"workspaceFolder": "/workspaces/${localWorkspaceFolderBasename}",
// Features to add to the dev container. More info: https://containers.dev/features.
"features": {
"ghcr.io/devcontainers/features/github-cli:1": {
"version": "latest"
}
},
"containerEnv": {
"PGHOST": "postgres",
"PGUSER": "postgres",
"PGPASSWORD": "postgres"
},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
// This can be used to network with other containers or the host.
// "forwardPorts": [3000, 5432],
// Use 'postCreateCommand' to run commands after the container is created.
"postCreateCommand": ".devcontainer/boot.sh",
// Configure tool-specific properties.
"customizations": {
"vscode": {
// Add the IDs of extensions you want installed when the container is created.
"extensions": [
"Shopify.ruby-lsp"
]
}
},
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
// "remoteUser": "root"
}