Valentin Lab
bf3b3fa59f
chg: dev: avoid ``exit`` in favor of ``return``
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
44ac8bf62c
fix: prevent permission errors when compose is writing cache files
Separate ``compose`` and ``compose-core`` cache location as the first
needs possibly user permission while the latter will require root
permission.
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
a4c6e9e7cd
fix: dev: small improvements !minor
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
225d1e5cce
fix: missing export on function ``docker_compose_store``
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
3ae01755f2
fix: management of ``compose.yml`` location
We need to parse the command line and modify it accordingly if option
``-f`` or ``--file`` is given.
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
813dd0c06b
new: enter fully setup compose image for debug
With ``ENTER=1``, one can enter the fully configured
container instead of launching compose.
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
5d0c90ff00
fix: remove error message about sessions that can't be deleted
Not a nice solution, but message are kept when using ``DEBUG``.
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
a968ccc3a9
chg: remove charm-store inner link support
Links were poorly supported and are a pain in the ass
due to docker volumes deferencing links in the container
side before making the bind mount, preventing overriding
links in the container file system.
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
ffe43b0194
new: print usage section in help !minor
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
33dcd642c5
new: dev: add and re-order function declaration
Add ``kal-shlib`` functions for next commits and
classify in 3 sections functions by source.
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
00b4206fc6
new: dev: debug messages on launcher
Using ``DEBUG=1`` on binary compose docker launcher prints
pretty-printed docker command launched as well as important
system variables.
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
e97351adb1
fix: non-root user could not launch compose
We want to propagate user's current ssh config, and have specially
crafted vars for each os/users.
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
4123198e70
new: timezone is fixed for containers
We prefer to create a file with the ``/etc/timezone`` information
in our own file directory to be shared read-only with containers.
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
87823ae45b
new: dev: make compose sourcable for eventual tests !minor
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
0c97d1f775
chg: dev: include color library and common element !minor
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
d9adfdfa7c
chg: dev: implement shellcheck advice !minor
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
1af2ae3312
fix: ``--no-hooks`` was not fully implemented
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
bcc8556412
fix: invalid usage of ``return``
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
d14f10e2a5
fix: invalid cache file names
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
6937945ea4
chg: raise waiting for tcp connection timeout
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
dd7bf70df8
fix: missing options in ``--help`` options
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
a3d694bf4e
new: ``!file-content`` modifier to allow including file contents in some config values
6 years ago
Valentin Lab
b690c921f4
fix: ``subordinate`` charm should not be launched
6 years ago
Valentin Lab
ffe47e82dd
fix: same ``host-resource`` would incorrectly be setup multiple times
This is an obvious typo that would also not break if host resource
setup failed.
6 years ago
Valentin Lab
8dfe137964
new: add ssh to docker image to support git ``host-resources`` on ssh.
6 years ago
Valentin Lab
162b84567f
fix: try to pair before summoning
Relations declared as auto summon was not trying to pair with an
existing service before.
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
58d227a704
fix: summon services requirement not to be ignored
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
8078505626
fix: spurious space in debug information !minor
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
b858e44af4
fix: incorrect detection of existing db container
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
8c756c562e
new: pkg: avoid spurious warnings from ``docker-compose run`` calls.
This helps charm direct actions to keep a tidy standard output, and allows
them to be used in scripts.
``docker-compose`` was updated to the latest version available (aka
``1.24.0``) and was patched to include what might have been forgotten
when implementing the ``COMPOSE_IGNORE_ORPHANS`` environment variable.
On ``compose`` side, we need to make sure to pass environment variables
that are to be used by ``docker-compose``.
PR: https://github.com/docker/compose/pull/7020
Signed-off-by: Valentin Lab <valentin.lab@kalysto.org>
5 years ago
Valentin Lab
04c6042b3a
new: macosx compatibility
5 years ago
Valentin Lab
503697ea6a
new: dev: update for kal-shlib-charm 0.5.0 compatibility
5 years ago
Valentin Lab
a4a8b65617
fix: remove subordinates from service list for final call of ``docker-compose``
5 years ago
Valentin Lab
a5ffe9dff7
new: allow to change server db docker run param and connection check command !api
5 years ago
Valentin Lab
bacb12e2e4
fix: error message typo !minor
5 years ago
Valentin Lab
3401c42e93
fix: prevent spurious output from possible ``docker pull`` to polute stdout
5 years ago
Valentin Lab
c9f8f2b3e4
fix: keep ``COMPOSE_DOCKER_IMAGE`` in subcalls.
5 years ago
Valentin Lab
d700a9f1b8
new: added ``docker_image_export_dir``, ``service_base_image_export_dir`` helper function
This implements a missing feature in docker to allow to export some
part of a docker image.
5 years ago
Valentin Lab
3ff8b02d40
fix: correctly set compose ``-i`` options only when needed
5 years ago
Valentin Lab
06cc478ad0
new: direct action do not decorate output anymore
We couldn't use efficiently the output of direct action in scripts.
5 years ago
Valentin Lab
c6feae7ef7
new: support "--without-relation" to remove a relation if needed.
5 years ago
Valentin Lab
b9175ac09e
fix: ``xargs`` would complain about ``LINE_MAX`` for some reason on some hosts.
6 years ago
Valentin Lab
8e2c239c1b
new: ensure ``compose-core`` is indeed outputing docker-compose errorlevel
6 years ago
Valentin Lab
32a0145e6e
fix: allow merging ``float`` values also.
6 years ago
Valentin Lab
cfd908b18d
new: added ``docker_get_uid_gid`` for charms.
6 years ago
Valentin Lab
bb666109a4
new: dev: added ``yaml_get_values`` helper function for charm.
6 years ago
Valentin Lab
9eb5cba55e
fix: dev: better caching of ``_get_rec_depth``.
6 years ago
Valentin Lab
cb4c8d7d79
chg: dev: don't print service as it's own dep in debug message.
6 years ago
Valentin Lab
c6693f56cb
fix: ``run-once`` service relying on sub-services would not have there sub-service called.
For instance ``letsencrypt`` would rely on ``cron``, and if not
explicitely mentionned in base of ``compose.yml``, ``compose up``
would not launch ``cron``.
6 years ago
Valentin Lab
82130814f8
fix: dev: bad cache would mess output of ``get_ordered_service_dependencies`` the second time.
6 years ago