Skip to content

Commit

Permalink
Merge pull request #2 from RoyAtanu/develop
Browse files Browse the repository at this point in the history
housekeeping changes
  • Loading branch information
RoyAtanu authored Jun 17, 2022
2 parents 73b7946 + a736dfa commit 378aba0
Show file tree
Hide file tree
Showing 5 changed files with 51 additions and 28 deletions.
44 changes: 22 additions & 22 deletions .github/workflows/build_executables.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,25 +31,25 @@ jobs:
cd dist/ && tar -czvf ../dckr_v0.${{ github.run_number }}_linux.tar.gz . && cd ..
ls -l dckr_v0.${{ github.run_number }}_linux.tar.gz
# - name: Create Release
# id: create_release
# uses: actions/create-release@v1
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# with:
# tag_name: v0.${{ github.run_number }}
# release_name: v0.${{ github.run_number }}
# body_path: ./releasenotes.md
# draft: false
# prerelease: true

# - name: Upload Release Asset
# id: upload-release-asset
# uses: actions/upload-release-asset@v1
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# with:
# upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
# asset_path: ./dckr_v0.${{ github.run_number }}_linux.tar.gz
# asset_name: dckr_v0.${{ github.run_number }}_linux.tar.gz
# asset_content_type: application/zip
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: v0.${{ github.run_number }}
release_name: v0.${{ github.run_number }}
body_path: ./releasenotes.md
draft: false
prerelease: true

- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./dckr_v0.${{ github.run_number }}_linux.tar.gz
asset_name: dckr_v0.${{ github.run_number }}_linux.tar.gz
asset_content_type: application/zip
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,18 @@ A Docker CLI alternative with shortcuts and added functionalities
![List functionality](documentation/images/screenshot_list.png?raw=true)
* ### **Cleanup** arguments
*dckr* provides shortcuts to bulk cleanup of docker artifacts by running single command

`./dckr container clean` will delete all containers at one go
* ### **Colored** console output
*dckr* prints colored texts in console for highlighting key information (e.g. # of items, status etc.)

****
## How to use this utility

Instructions to use the CLI to can be found by running `./dckr help`

Refer `dckr/help.py` for details

****
## How to build the executable from source
### Prerequisites
Expand Down
4 changes: 2 additions & 2 deletions dckr/images.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ def HandleImage(client):
if sys.argv[2].lower() == 'clean':
choice = input(f'Total {colorize.colorizeNumber(len(images))} will be removed. Proceed (y/n)? ')
if choice.lower() == 'y' or choice.lower() == 'yes':
# for i in images:
# client.images.remove(i.attrs['Id'][7:19])
for i in images:
client.images.remove(i.attrs['Id'][7:19], force=True)
print(f'All images removed')
else:
print(f'Image remove aborted')
Expand Down
8 changes: 4 additions & 4 deletions releasenotes.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Functions currently available with this build
- Docker artifacts -> container and image
- search and list
- Docker artifacts -> container, image, volume
- search, list, clean

Changes in this Release
- Workflow updated for automatic release creation and artifact upload
- README.md updated
- support for volume added
- CLI help added
14 changes: 14 additions & 0 deletions test/create_objects.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# pull images
docker pull busybox
docker pull hello-world
docker pull alpine

# start containers
docker run -d busybox
docker run -d hello-world
docker run -d alpine

# create volumes
docker volume create --driver local volume1
docker volume create --driver local volume2
docker volume create --driver local volume3

0 comments on commit 378aba0

Please sign in to comment.