Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/davidecavestro/usql-docker
Docker image for xo/usql - the universal command-line interface for SQL databases
https://github.com/davidecavestro/usql-docker
docker-image sql-client usql
Last synced: 16 days ago
JSON representation
Docker image for xo/usql - the universal command-line interface for SQL databases
- Host: GitHub
- URL: https://github.com/davidecavestro/usql-docker
- Owner: davidecavestro
- License: mit
- Created: 2022-05-19T16:42:49.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-10-21T14:12:23.000Z (17 days ago)
- Last Synced: 2024-10-21T23:17:06.942Z (17 days ago)
- Topics: docker-image, sql-client, usql
- Homepage:
- Size: 20.5 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# usql-docker
> [!IMPORTANT]
> Please consider using the official usql image recently published at https://hub.docker.com/r/usql/usqlUnofficial multiarch docker image for [usql](https://github.com/xo/usql), the universal command-line interface for SQL databases.
Get it from GitHub container registry as
`docker pull ghcr.io/davidecavestro/usql:latest`
or from dockerhub as
`docker pull davidecavestro/usql:latest`
## Usage
You can test it with a local sqlite db, i.e. the following command
`docker run --rm -it -v $(pwd)/data:/data davidecavestro/usql:latest sq://data/test.db`
starts the shell where you can play around as follows
```
me@localhost:~$ docker run --rm -it -v $(pwd)/data:/data davidecavestro/usql:latest sq://data/test.db
Connected with driver sqlite3 (SQLite3 3.38.5)
Type "help" for help.sq:data/test.db=> CREATE TABLE foo (id int, value text);
CREATE TABLE
sq:data/test.db=> INSERT INTO foo VALUES (1, 'bar');
INSERT 1
sq:data/test.db=> INSERT INTO foo VALUES (2, 'baz');
INSERT 1
sq:data/test.db=> SELECT * FROM foo;
id | value
----+-------
1 | bar
2 | baz
(2 rows)sq:data/test.db=> \q
```