summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLokesh Mandvekar <lsm5@fedoraproject.org>2018-04-07 23:02:44 -0400
committerLokesh Mandvekar <lsm5@fedoraproject.org>2018-04-07 23:02:44 -0400
commit61290b1bc7bdace32a8f666ac2bfed4756ca0e14 (patch)
tree6d9db01112505bf623d6aa47767b7946657488d0
parentc14385fae0a8b27270ec0f8b77859c14656b1f68 (diff)
downloadbuildah-61290b1bc7bdace32a8f666ac2bfed4756ca0e14.tar.gz
buildah-61290b1bc7bdace32a8f666ac2bfed4756ca0e14.tar.xz
buildah-61290b1bc7bdace32a8f666ac2bfed4756ca0e14.zip
buildah-0.16-2.git4743c2e
- autobuilt commit 4743c2e Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
-rw-r--r--.gitignore1
-rw-r--r--buildah.spec7
-rw-r--r--sources2
-rw-r--r--tests/README.md3
-rw-r--r--tests/binary.yml10
-rw-r--r--tests/callback_plugins/log.py193
-rw-r--r--tests/roles/binary/tasks/buildah.yml15
-rw-r--r--tests/roles/binary/tasks/main.yml4
-rw-r--r--tests/roles/binary/tasks/runc.yml16
-rw-r--r--tests/roles/cli/tasks/add.yaml41
-rw-r--r--tests/roles/cli/tasks/bud.yaml24
-rw-r--r--tests/roles/cli/tasks/cleanup.yaml4
-rw-r--r--tests/roles/cli/tasks/config.yaml16
-rw-r--r--tests/roles/cli/tasks/containers.yaml18
-rw-r--r--tests/roles/cli/tasks/copy.yaml41
-rw-r--r--tests/roles/cli/tasks/from.yaml12
-rw-r--r--tests/roles/cli/tasks/main.yaml44
-rw-r--r--tests/roles/cli/tasks/mount.yaml27
-rw-r--r--tests/roles/cli/tasks/prepare-containers.yaml6
-rw-r--r--tests/roles/cli/tasks/push.yaml60
-rw-r--r--tests/roles/cli/tasks/tag.yaml43
-rw-r--r--tests/roles/prepare-env/tasks/main.yml41
-rw-r--r--tests/roles/tear-down/tasks/main.yml6
-rw-r--r--tests/rpm.yml9
-rwxr-xr-xtests/test_binary.sh1
-rwxr-xr-xtests/test_rpm.sh1
-rw-r--r--tests/tests.yml12
27 files changed, 7 insertions, 650 deletions
diff --git a/.gitignore b/.gitignore
index 36f6083..f2d124c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -17,3 +17,4 @@
/buildah-ef0ca9c.tar.gz
/buildah-d1330a5.tar.gz
/buildah-82529cd.tar.gz
+/buildah-4743c2e.tar.gz
diff --git a/buildah.spec b/buildah.spec
index 70e8bf9..57ee4fb 100644
--- a/buildah.spec
+++ b/buildah.spec
@@ -14,12 +14,12 @@
# https://github.com/projectatomic/buildah
%global provider_prefix %{provider}.%{provider_tld}/%{project}/%{repo}
%global import_path %{provider_prefix}
-%global commit0 82529cdf31628d4636214d93b8d28a05443fce60
+%global commit0 4743c2e7f132010a01de2d9cf96d10244fced423
%global shortcommit0 %(c=%{commit0}; echo ${c:0:7})
Name: %{repo}
Version: 0.16
-Release: 1.git%{shortcommit0}%{?dist}
+Release: 2.git%{shortcommit0}%{?dist}
Summary: A command line tool used for creating OCI Images
License: ASL 2.0
URL: https://%{provider_prefix}
@@ -84,6 +84,9 @@ make DESTDIR=%{buildroot} PREFIX=%{_prefix} install install.completions
%{_datadir}/bash-completion/completions/%{name}
%changelog
+* Sun Apr 08 2018 Lokesh Mandvekar <lsm5@fedoraproject.org> - 0.16-2.git4743c2e
+- autobuilt commit 4743c2e
+
* Wed Apr 4 2018 Dan Walsh <dwalsh@redhat.com> 0.16-1
- Add support for shell
- Vendor in latest containers/image
diff --git a/sources b/sources
index 5083be7..bb0757b 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-SHA512 (buildah-82529cd.tar.gz) = 979a9e1cef5368ae03c0f67b9649b7f74ab3c294e1e1efe2b23e4e2a7ddeb143d73ee8cdd2cbb0bba9266fdf5db059cac0dcdafb461f3e0f60cdecf6e21684a5
+SHA512 (buildah-4743c2e.tar.gz) = 2e2294c6602b53142525a0ee83ec57678f8588b133fd709b998299649e00233de594837ed87a6467e02876ea1cc599e975f46fdbfd737287afb7a4ae302ec8c9
diff --git a/tests/README.md b/tests/README.md
deleted file mode 100644
index 3a997a6..0000000
--- a/tests/README.md
+++ /dev/null
@@ -1,3 +0,0 @@
-Buildah - a tool which facilitates building OCI container images
-
-When executing the buildah bud testing, it will cost much time as it is building image in the background.
diff --git a/tests/binary.yml b/tests/binary.yml
deleted file mode 100644
index 1c7803d..0000000
--- a/tests/binary.yml
+++ /dev/null
@@ -1,10 +0,0 @@
----
-# test buildah
-- hosts: all
- become: true
- tags:
- - classic
- roles:
- - binary
- - prepare-env
- - cli
diff --git a/tests/callback_plugins/log.py b/tests/callback_plugins/log.py
deleted file mode 100644
index f4f1ce9..0000000
--- a/tests/callback_plugins/log.py
+++ /dev/null
@@ -1,193 +0,0 @@
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-# Inspired from: https://github.com/redhat-openstack/khaleesi/blob/master/plugins/callbacks/human_log.py
-# Further improved support Ansible 2.0
-
-from __future__ import (absolute_import, division, print_function)
-__metaclass__ = type
-
-try:
- from ansible.plugins.callback import CallbackBase
- BASECLASS = CallbackBase
-except ImportError: # < ansible 2.1
- BASECLASS = DEFAULT_MODULE.CallbackModule
-
-import os, sys
-reload(sys)
-sys.setdefaultencoding('utf-8')
-
-try:
- import simplejson as json
-except ImportError:
- import json
-
-# Fields to reformat output for
-FIELDS = ['cmd', 'command', 'start', 'end', 'delta', 'msg', 'stdout',
- 'stderr', 'results', 'failed', 'reason']
-
-
-class CallbackModule(CallbackBase):
-
- """
- Ansible callback plugin for human-readable result logging
- """
- CALLBACK_VERSION = 2.0
- CALLBACK_TYPE = 'notification'
- CALLBACK_NAME = 'human_log'
- CALLBACK_NEEDS_WHITELIST = False
-
- def __init__(self, *args, **kwargs):
- # pylint: disable=non-parent-init-called
- BASECLASS.__init__(self, *args, **kwargs)
- self.artifacts = './artifacts'
- self.result_file = os.path.join(self.artifacts, 'test.log')
- if not os.path.exists(self.artifacts):
- os.makedirs(self.artifacts)
- with open(self.result_file, 'w'): pass
-
- def human_log(self, data, taskname, status):
- if type(data) == dict:
- with open('./artifacts/test.log', 'a') as f:
- f.write("\n\n")
- f.write("# TASK NAME: %s \n" % taskname)
- f.write("# STATUS: %s \n\n" % status)
- f.write("Outputs: \n\n")
- for field in FIELDS:
- no_log = data.get('_ansible_no_log', False)
- if field in data.keys() and data[field] and no_log != True:
- output = self._format_output(data[field])
- # The following two lines are a hack to make it work with UTF-8 characters
- if type(output) != list:
- output = output.encode('utf-8', 'replace')
- #self._display.display("\n{0}:\n{1}".format(field, output.replace("\\n","\n")), log_only=False)
- with open('./artifacts/test.log', 'a') as f:
- f.write("{0}: {1}".format(field, output.replace("\\n","\n"))+"\n")
-
-
- def _format_output(self, output):
- # Strip unicode
- if type(output) == unicode:
- output = output.encode(sys.getdefaultencoding(), 'replace')
-
- # If output is a dict
- if type(output) == dict:
- return json.dumps(output, indent=2, sort_keys=True)
-
- # If output is a list of dicts
- if type(output) == list and type(output[0]) == dict:
- # This gets a little complicated because it potentially means
- # nested results, usually because of with_items.
- real_output = list()
- for index, item in enumerate(output):
- copy = item
- if type(item) == dict:
- for field in FIELDS:
- if field in item.keys():
- copy[field] = self._format_output(item[field])
- real_output.append(copy)
- return json.dumps(output, indent=2, sort_keys=True)
-
- # If output is a list of strings
- if type(output) == list and type(output[0]) != dict:
- return '\n'.join(output)
-
- # Otherwise it's a string, (or an int, float, etc.) just return it
- return str(output)
-
- ####### V2 METHODS ######
- def v2_on_any(self, *args, **kwargs):
- pass
-
- def v2_runner_on_failed(self, result, ignore_errors=False):
- self.human_log(result._result, result._task.name, "fail")
-
- def v2_runner_on_ok(self, result):
- self.human_log(result._result, result._task.name, "pass")
-
- def v2_runner_on_skipped(self, result):
- pass
-
- def v2_runner_on_unreachable(self, result):
- self.human_log(result._result, result._task.name, "unreachable")
-
- def v2_runner_on_no_hosts(self, task):
- pass
-
- def v2_runner_on_async_poll(self, result):
- self.human_log(result._result, result._task.name, "")
-
- def v2_runner_on_async_ok(self, host, result):
- self.human_log(result._result, result._task.name, "pass")
-
- def v2_runner_on_async_failed(self, result):
- self.human_log(result._result, result._task.name, "fail")
-
- def v2_playbook_on_start(self, playbook):
- pass
-
- def v2_playbook_on_notify(self, result, handler):
- pass
-
- def v2_playbook_on_no_hosts_matched(self):
- pass
-
- def v2_playbook_on_no_hosts_remaining(self):
- pass
-
- def v2_playbook_on_task_start(self, task, is_conditional):
- pass
-
- def v2_playbook_on_vars_prompt(self, varname, private=True, prompt=None,
- encrypt=None, confirm=False, salt_size=None,
- salt=None, default=None):
- pass
-
- def v2_playbook_on_setup(self):
- pass
-
- def v2_playbook_on_import_for_host(self, result, imported_file):
- pass
-
- def v2_playbook_on_not_import_for_host(self, result, missing_file):
- pass
-
- def v2_playbook_on_play_start(self, play):
- pass
-
- def v2_playbook_on_stats(self, stats):
- pass
-
- def v2_on_file_diff(self, result):
- pass
-
- def v2_playbook_on_item_ok(self, result):
- pass
-
- def v2_playbook_on_item_failed(self, result):
- pass
-
- def v2_playbook_on_item_skipped(self, result):
- pass
-
- def v2_playbook_on_include(self, included_file):
- pass
-
- def v2_playbook_item_on_ok(self, result):
- pass
-
- def v2_playbook_item_on_failed(self, result):
- pass
-
- def v2_playbook_item_on_skipped(self, result):
- pass
diff --git a/tests/roles/binary/tasks/buildah.yml b/tests/roles/binary/tasks/buildah.yml
deleted file mode 100644
index 5122105..0000000
--- a/tests/roles/binary/tasks/buildah.yml
+++ /dev/null
@@ -1,15 +0,0 @@
----
-- name: pull latest buildah source from github
- git:
- repo: https://github.com/projectatomic/buildah
- dest: "{{ HOME }}/go/src/github.com/projectatomic/buildah"
-
-- name: make binary for buildah
- command: make
- args:
- chdir: "{{ HOME }}/go/src/github.com/projectatomic/buildah"
-
-- name: install buildah to /usr/local/bin
- command: make install
- args:
- chdir: "{{ HOME }}/go/src/github.com/projectatomic/buildah"
diff --git a/tests/roles/binary/tasks/main.yml b/tests/roles/binary/tasks/main.yml
deleted file mode 100644
index 771725d..0000000
--- a/tests/roles/binary/tasks/main.yml
+++ /dev/null
@@ -1,4 +0,0 @@
----
-- import_tasks: runc.yml
-
-- import_tasks: buildah.yml
diff --git a/tests/roles/binary/tasks/runc.yml b/tests/roles/binary/tasks/runc.yml
deleted file mode 100644
index d64d5fb..0000000
--- a/tests/roles/binary/tasks/runc.yml
+++ /dev/null
@@ -1,16 +0,0 @@
----
-- name: pull latest runc source from github
- git:
- repo: https://github.com/opencontainers/runc
- dest: "{{ HOME }}/go/src/github.com/opencontainers/runc"
-
-- name: building runc for buildah runtime
- command: make
- args:
- chdir: "{{ HOME }}/go/src/github.com/opencontainers/runc"
-
-- name: copy runc to /usr/bin
- copy:
- remote_src: True
- src: "{{ HOME }}/go/src/github.com/opencontainers/runc/runc"
- dest: /usr/bin/runc
diff --git a/tests/roles/cli/tasks/add.yaml b/tests/roles/cli/tasks/add.yaml
deleted file mode 100644
index 0bd6498..0000000
--- a/tests/roles/cli/tasks/add.yaml
+++ /dev/null
@@ -1,41 +0,0 @@
----
-- name: buildah add
- command: buildah add nginxc /tmp/buildah/bud/Dockerfile
-
-- name: check buildah add
- command: ls {{mount.stdout}}/Dockerfile
-
-- name: buildah add to destination
- command: buildah add nginxc /tmp/buildah/bud/Dockerfile /home
-
-- name: check buildah add to
- command: ls {{mount.stdout}}/home/Dockerfile
-
-- name: buildah add URL
- command: buildah add nginxc https://github.com/projectatomic/buildah/raw/master/README.md
-
-- name: check buildah add URL
- command: ls {{mount.stdout}}/README.md
-
-- name: buildah add URL to destination
- command: buildah add nginxc https://github.com/projectatomic/buildah/raw/master/README.md /home
-
-- name: check buildah add URL to destination
- command: ls {{mount.stdout}}/home/README.md
-
-- name: Download buildah README.md
- get_url:
- url: https://github.com/projectatomic/buildah/raw/master/README.md
- dest: /tmp/buildah/
-
-- name: buildah add dir
- command: buildah add nginxc /tmp
-
-- name: check buildah add dir
- command: ls {{mount.stdout}}/buildah/README.md
-
-- name: buildah add dir to destination
- command: buildah add nginxc /tmp /home
-
-- name: check buildah add dir to destination
- command: ls {{mount.stdout}}/home/buildah/README.md
diff --git a/tests/roles/cli/tasks/bud.yaml b/tests/roles/cli/tasks/bud.yaml
deleted file mode 100644
index 1f1c678..0000000
--- a/tests/roles/cli/tasks/bud.yaml
+++ /dev/null
@@ -1,24 +0,0 @@
----
-- name: buildah bud localfile
- command: buildah bud -t testing/nginx --pull /tmp/buildah/bud
-
-- name: check bud images with buildah images command
- shell: buildah images | grep testing/nginx
-
-- name: buildah bud -f localfile
- command: buildah bud -t testing/nginx2 -f /tmp/buildah/bud/Dockerfile .
-
-- name: buildah bud URL
- command: buildah bud -t testing/nginx3 http://localhost/bud/Dockerfile.tar.gz
-
-- name: buildah build-using-dockerfile localfile
- command: buildah build-using-dockerfile -t testing/nginx4 /tmp/buildah/bud
-
-- name: buildah build-using-dockerfile -f localfile
- command: buildah build-using-dockerfile -t testing/nginx5 --file /tmp/buildah/bud/Dockerfile .
-
-- name: buildah build-using-dockerfile URL
- command: buildah build-using-dockerfile --tag testing/nginx6 http://localhost/bud/Dockerfile.tar.gz
-
-- name: buildah rmi
- command: buildah rmi testing/nginx{2..6}
diff --git a/tests/roles/cli/tasks/cleanup.yaml b/tests/roles/cli/tasks/cleanup.yaml
deleted file mode 100644
index 45f31d5..0000000
--- a/tests/roles/cli/tasks/cleanup.yaml
+++ /dev/null
@@ -1,4 +0,0 @@
----
-- name: remove buildah containers after testing
- command: buildah rm busybox nginxc nginxc-2
- ignore_errors: true
diff --git a/tests/roles/cli/tasks/config.yaml b/tests/roles/cli/tasks/config.yaml
deleted file mode 100644
index 91e8bc3..0000000
--- a/tests/roles/cli/tasks/config.yaml
+++ /dev/null
@@ -1,16 +0,0 @@
----
-- name: buildah config workingdir
- command: buildah config --workingdir /opt nginxc
-
-- name: get buildah config workingdir
- command: buildah run nginxc "pwd"
- register: checkworkingdir
- failed_when: "'/opt' not in checkworkingdir.stdout"
-
-- name: buildah config env
- command: buildah config --env foo=bar nginxc
-
-- name: get buildah config env
- command: buildah run nginxc env
- register: env
- failed_when: "'foo=bar' not in env.stdout"
diff --git a/tests/roles/cli/tasks/containers.yaml b/tests/roles/cli/tasks/containers.yaml
deleted file mode 100644
index fa9add6..0000000
--- a/tests/roles/cli/tasks/containers.yaml
+++ /dev/null
@@ -1,18 +0,0 @@
----
-- name: buildah containers
- shell: buildah containers | grep nginxc
-
-- name: buildah containers -q
- shell: buildah containers -q | grep -v nginxc
-
-- name: buildah containers -n
- shell: buildah containers -n | grep -v NAME
-
-- name: buildah containers --notruncate
- command: buildah containers -- notruncate
-
-- name: buildah containers --all
- command: buildah containers --all
-
-- name: buildah containers --json
- command: buildah containers --json
diff --git a/tests/roles/cli/tasks/copy.yaml b/tests/roles/cli/tasks/copy.yaml
deleted file mode 100644
index 3f0d8c5..0000000
--- a/tests/roles/cli/tasks/copy.yaml
+++ /dev/null
@@ -1,41 +0,0 @@
----
-- name: buildah copy
- command: buildah copy nginxc-2 /tmp/buildah/bud/Dockerfile
-
-- name: check buildah copy
- command: ls {{mount.stdout}}/Dockerfile
-
-- name: buildah copy to destination
- command: buildah copy nginxc-2 /tmp/buildah/bud/Dockerfile /home
-
-- name: check buildah copy to
- command: ls {{mount.stdout}}/home/Dockerfile
-
-- name: buildah copy URL
- command: buildah copy nginxc-2 https://github.com/projectatomic/buildah/raw/master/README.md
-
-- name: check buildah copy URL
- command: ls {{mount.stdout}}/README.md
-
-- name: buildah copy URL to destination
- command: buildah copy nginxc-2 https://github.com/projectatomic/buildah/raw/master/README.md /home
-
-- name: check buildah copy URL to destination
- command: ls {{mount.stdout}}/home/README.md
-
-- name: Download buildah README.md
- get_url:
- url: https://github.com/projectatomic/buildah/raw/master/README.md
- dest: /tmp/buildah/
-
-- name: buildah copy dir
- command: buildah copy nginxc-2 /tmp/buildah
-
-- name: check buildah copy dir
- command: ls {{mount.stdout}}/README.md
-
-- name: buildah copy dir to destination
- command: buildah copy nginxc-2 /tmp /home
-
-- name: check buildah copy dir to destination
- command: ls {{mount.stdout}}/home/buildah/README.md
diff --git a/tests/roles/cli/tasks/from.yaml b/tests/roles/cli/tasks/from.yaml
deleted file mode 100644
index e694b10..0000000
--- a/tests/roles/cli/tasks/from.yaml
+++ /dev/null
@@ -1,12 +0,0 @@
----
-- name: buildah from pull
- command: buildah from --pull nginx
-
-- name: buildah from pull always
- command: buildah from --pull-always nginx
-
-- name: buildah from with name
- command: buildah from --name nginx nginx
-
-- name: clean from testings
- command: buildah delete nginx nginx-working-container nginx-working-container-2
diff --git a/tests/roles/cli/tasks/main.yaml b/tests/roles/cli/tasks/main.yaml
deleted file mode 100644
index f709887..0000000
--- a/tests/roles/cli/tasks/main.yaml
+++ /dev/null
@@ -1,44 +0,0 @@
----
-- block:
- - name: prepare containers nginxc
- import_tasks: prepare-containers.yaml
- tags:
- - nginxc
-
- - name: buildah containers
- import_tasks: containers.yaml
- tags:
- - ctr
-
- - name: buildah from
- import_tasks: from.yaml
- tags:
- - from
-
- - name: buildah mount
- import_tasks: mount.yaml
- tags:
- - mount
-
- - name: buildah tag
- import_tasks: tag.yaml
- tags:
- - tag
-
- - name: buildah config
- import_tasks: config.yaml
- tags:
- - config
-
- - name: buildah push
- import_tasks: push.yaml
- tags:
- - push
-
- - name: buildah build-using-dockerfile
- import_tasks: bud.yaml
- tags:
- - bud
-
- always:
- - import_tasks: cleanup.yaml
diff --git a/tests/roles/cli/tasks/mount.yaml b/tests/roles/cli/tasks/mount.yaml
deleted file mode 100644
index 09bd901..0000000
--- a/tests/roles/cli/tasks/mount.yaml
+++ /dev/null
@@ -1,27 +0,0 @@
----
-- name: buildah mount container nginxc
- command: buildah mount nginxc
- register: mount
-
-- name: buildah mount without args will list all mounts
- shell: buildah mount | grep storage
-
-- name: buildah add
- import_tasks: add.yaml
- tags:
- - add
-
-- name: buildah umount
- command: buildah umount nginxc
-
-- name: buildah mount --notruncate
- command: buildah mount --notruncate nginxc-2
- register: mount
-
-- name: buildah copy
- import_tasks: copy.yaml
- tags:
- - copy
-
-- name: buildah unmount
- command: buildah unmount nginxc-2
diff --git a/tests/roles/cli/tasks/prepare-containers.yaml b/tests/roles/cli/tasks/prepare-containers.yaml
deleted file mode 100644
index 1477e62..0000000
--- a/tests/roles/cli/tasks/prepare-containers.yaml
+++ /dev/null
@@ -1,6 +0,0 @@
----
-- name: prepare container nginxc for later testing
- command: buildah from --pull --name nginxc nginx
-
-- name: prepare container nginxc-2 for later testing
- command: buildah from --name nginxc-2 nginx
diff --git a/tests/roles/cli/tasks/push.yaml b/tests/roles/cli/tasks/push.yaml
deleted file mode 100644
index cc38b51..0000000
--- a/tests/roles/cli/tasks/push.yaml
+++ /dev/null
@@ -1,60 +0,0 @@
----
-- name: pull busybox before push
- command: buildah from --pull --name busybox busybox
-
-- name: buildah push image to containers-storage
- command: buildah push docker.io/busybox:latest containers-storage:docker.io/busybox:latest
-
-- name: buildah push image to docker daemon
- command: buildah push docker.io/busybox:latest docker-daemon:docker.io/buildah/busybox:latest
-
-- name: check buildah/busybox exist in docker daemon
- command: docker images docker.io/buildah/busybox:latest
-
-- name: buildah push image to docker local registry
- command: buildah push --tls-verify=false docker.io/busybox:latest docker://localhost:5000/buildah/busybox:latest
-
-- name: create /tmp/buildah/busybox
- file: path=/tmp/buildah/docker state=directory
-
-- name: rm busybox.tar because docker archive does not support modify
- file: path=/tmp/buildah/docker/busybox.tar state=absent
-
-- name: buildah push image to docker-archive
- command: buildah push docker.io/busybox:latest docker-archive:/tmp/buildah/docker/busybox.tar:latest
-
-- name: check docker archive exist
- file: path=/tmp/buildah/docker/busybox.tar state=file
-
-- name: create /tmp/buildah/dir
- file: path=/tmp/buildah/dir state=directory
-
-- name: buildah push image to dir
- command: buildah push docker.io/busybox:latest dir:/tmp/buildah/dir
-
-- name: create /tmp/buildah/oci
- file: path=/tmp/buildah/oci state=directory
-
-- name: buildah push image to oci
- command: buildah push docker.io/busybox:latest oci:/tmp/buildah/oci:latest
-
-- name: buildah push image to oci archive
- command: buildah push docker.io/busybox:latest oci-archive:/tmp/buildah/oci/busybox.tar:latest
-
-- name: check oci archive exist
- file: path=/tmp/buildah/oci/busybox.tar state=file
-
-- name: init default ostree repo
- command: ostree --repo=/ostree/repo init
-
-- name: create /tmp/buildah/ostree/repo
- file: path=/tmp/buildah/ostree/repo state=directory
-
-- name: init tmp ostree repo
- command: ostree --repo=/tmp/buildah/ostree/repo init
-
-- name: buildah push image to ostree
- command: buildah push docker.io/busybox:latest ostree:busybox:latest
-
-- name: buildah push image to non-default ostree repo
- command: buildah push docker.io/busybox:latest ostree:busybox:latest@/tmp/buildah/ostree/repo
diff --git a/tests/roles/cli/tasks/tag.yaml b/tests/roles/cli/tasks/tag.yaml
deleted file mode 100644
index 32767ba..0000000
--- a/tests/roles/cli/tasks/tag.yaml
+++ /dev/null
@@ -1,43 +0,0 @@
----
-- name: buildah from --pull busybox
- command: buildah from busybox
-
-- name: buildah tag by name
- command: buildah tag busybox busybox1
-
-- name: check busybox1 exists
- shell: buildah images | grep busybox1
-
-- name: get image id
- command: buildah images -q busybox1
- register: busyboxID
-
-- name: buildah tag by ID
- command: buildah tag {{busyboxID.stdout}} busybox2
-
-- name: check busybox2 exists
- shell: buildah images | grep busybox2
-
-- name: buildah from tagged image
- command: buildah from busybox1
-
-- name: mount the container which using tagged image
- command: buildah mount busybox1-working-container
-
-- name: buildah umount the container
- command: buildah umount busybox1-working-container
-
-- name: buildah rm container busybox
- command: buildah rm busybox-working-container
-
-- name: buildah rm container busybox1
- command: buildah rm busybox1-working-container
-
-- name: buildah rmi tagged image
- command: buildah rmi busybox{1..2}
-
-- name: check image busybox is not deleted
- shell: buildah images | grep busybox
-
-- name: buildah rmi image busybox
- command: buildah rmi busybox
diff --git a/tests/roles/prepare-env/tasks/main.yml b/tests/roles/prepare-env/tasks/main.yml
deleted file mode 100644
index bc46794..0000000
--- a/tests/roles/prepare-env/tasks/main.yml
+++ /dev/null
@@ -1,41 +0,0 @@
----
-- name: install required packages for testings
- package:
- name: "{{ item }}"
- state: latest
- with_items:
- - docker
- - python-docker-py
- - buildah
- - docker-distribution
- - ostree
- - httpd
- - libselinux-python
-
-- name: start docker daemon
- systemd: state=started name=docker
-
-- name: create /ostree/repo
- file: path=/ostree/repo state=directory
-
-- name: ensure docker-distribution service is running
- systemd: state=started name=docker-distribution
-
-- name: creates directory buildah testing
- file: path=/tmp/buildah/bud state=directory
-
-- name: download Dockerfile
- get_url:
- url: https://github.com/fedora-cloud/Fedora-Dockerfiles/raw/master/nginx/Dockerfile
- dest: /tmp/buildah/bud/Dockerfile
-
-- name: creates a bud directory in /var/www/html
- file: path=/var/www/html/bud state=directory
-
-- name: archive dockerfile into httpd directory
- command: tar zcvf /var/www/html/bud/Dockerfile.tar.gz Dockerfile
- args:
- chdir: /tmp/buildah/bud
-
-- name: start httpd service
- systemd: state=started name=httpd
diff --git a/tests/roles/tear-down/tasks/main.yml b/tests/roles/tear-down/tasks/main.yml
deleted file mode 100644
index f54186d..0000000
--- a/tests/roles/tear-down/tasks/main.yml
+++ /dev/null
@@ -1,6 +0,0 @@
----
-- name: stop docker-distribution service
- systemd: state=stopped name=docker-distribution
-
-- name: stop httpd service
- systemd: state=stopped name=httpd
diff --git a/tests/rpm.yml b/tests/rpm.yml
deleted file mode 100644
index 27a9349..0000000
--- a/tests/rpm.yml
+++ /dev/null
@@ -1,9 +0,0 @@
----
-# test buildah
-- hosts: all
- become: true
- tags:
- - classic
- roles:
- - prepare-env
- - cli
diff --git a/tests/test_binary.sh b/tests/test_binary.sh
deleted file mode 100755
index 1290479..0000000
--- a/tests/test_binary.sh
+++ /dev/null
@@ -1 +0,0 @@
-ansible-playbook -i inventory binary.yml "$@"
diff --git a/tests/test_rpm.sh b/tests/test_rpm.sh
deleted file mode 100755
index 3634f61..0000000
--- a/tests/test_rpm.sh
+++ /dev/null
@@ -1 +0,0 @@
-ansible-playbook -i inventory buildah_rpm.yml "$@"
diff --git a/tests/tests.yml b/tests/tests.yml
deleted file mode 100644
index 74f63e8..0000000
--- a/tests/tests.yml
+++ /dev/null
@@ -1,12 +0,0 @@
----
-# test buildah
-- hosts: localhost
- become: true
- tags:
- - classic
- roles:
- - prepare-env
- - role: cli
- tags:
- - cli
- - tear-down