Skip to content

Commit

Permalink
fix(suse): fix support to install compose from PackageHub on SLES 15
Browse files Browse the repository at this point in the history
To actually install the packages, you need to set the following in your
pillar because the PackageHub repos are not enabled by default on SLES.

```YAML
docker:
  pkg:
    docker:
      use_upstream: 'package'
    compose:
      use_upstream: 'package'
```
  • Loading branch information
ypid-geberit committed Aug 24, 2021
1 parent 16cc758 commit 56b4080
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 1 deletion.
12 changes: 12 additions & 0 deletions docker/codenamemap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,15 @@ precise:
deps:
- linux-image-generic-lts-raring
- linux-headers-generic-lts-raring

SUSE Linux Enterprise Server 15:
pkg:
compose:
commands:
- docker-compose

SUSE Linux Enterprise Server 15 SP1:
pkg:
compose:
commands:
- docker-compose
4 changes: 4 additions & 0 deletions docker/osfamilymap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,10 @@ Suse:
- gzip
docker:
name: docker
compose:
# https://packagehub.suse.com/packages/python-docker-compose/
commands:
- python-docker-compose

MacOS:
identity:
Expand Down
9 changes: 8 additions & 1 deletion test/integration/archive/controls/archive_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,13 @@
impact 1.0
title 'should be installed'

case platform[:family]
when 'suse'
compose_bin = '/usr/local/bin/python-docker-compose'
else
compose_bin = '/usr/local/bin/docker-compose'
end

describe file('/usr/local/docker-19.03.9/bin') do
it { should exist }
it { should be_directory }
Expand Down Expand Up @@ -86,7 +93,7 @@
its('mode') { should cmp '0755' }
its('type') { should eq :file }
end
describe file('/usr/local/bin/docker-compose') do
describe file(compose_bin) do
it { should be_symlink }
it { should be_file }
it { should_not be_directory }
Expand Down

0 comments on commit 56b4080

Please sign in to comment.