Skip to content

Conversation

@jjustin
Copy link
Contributor

@jjustin jjustin commented Aug 1, 2017

Request for merge of 'dev' branch to 'master'
Use of features is described in deb/Readme.md

Copy link
Contributor

@dominikznidar dominikznidar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good but needs some more polishing

README.md Outdated

It is possible to automate deployment of packages by combining this repository with Travis CI.

Examples of `.travis.yml` and `Makefile` used for autamatic deployment of go project can be found in repository
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

automatic

Makefile_example Outdated
DESC := "description"
MAINTAINER := "Maintainer name"
LICENSE := "License here"
DEPENDENCIES := "" #Add dependencies here and add '-d $(DEPENDENCIES)' to fpm in pkg/% block
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please follow the already existing formatting.

deb/Makefile Outdated
@@ -0,0 +1,10 @@
ZIPPED := s3apt.py gnupg.py debian/*
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could be formatted in a better way :)

deb/Makefile Outdated
ZIPPED := s3apt.py gnupg.py debian/*


set: requires package
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should set be replaced with all?

deb/Makefile Outdated
pip install -t . -r requirements.txt

package:
zip code.zip $(ZIPPED) No newline at end of file
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's always a good idea to also add clean target that removes all the clutter you wouldn't commit anyway generated by other make commands. Additionally those same files should be listed in .gitignore. (I'm mainly talking about make requires)

deb/README.md Outdated

Compress all needed files
```
zip code.zip s3apt.py gnupg.py debian/*
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be updated

deb/README.md Outdated
```
git clone https://github.com/tactycal/lambdaRepos.git
cd lambdaRepos/deb
pip install -t . -r requirements.txt
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have a make command in place for this

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On the other hand, just use make commands in the readme.

deb/README.md Outdated
* Object Removed(All), suffix 'deb'
* If you are using certain directory as a repo, set it as prefix

Upload `code.zip` to lambda function
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be possible to replace this with AWS' CLI?

deb/s3apt.py Outdated
build_release_file(prefix)

#Sign Release file
if not os.environ['GPG_KEY']=='':
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

os.environ['GPG_KEY'] != '' is a more common option

deb/s3apt.py Outdated
release_file = release_file +(str(stat.st_size) + ' Packages\nSHA256:\n '+sha256 )
for i in range(0,17-len(str(stat.st_size))):
release_file = release_file +(' ')
release_file = release_file +(str(stat.st_size) + ' Packages')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All the repetitions of release_file make this really hard to read.

  • release_file = release_file could be replaced with release_file +=
  • str(stat.st_size) + ' Packages\nSHA1:\n '+sha1 could be replaced with "%d Packages\nSHA1:\n %s" % stat.st_size, sha1

@jjustin jjustin force-pushed the dev branch 4 times, most recently from 7e27b1c to cf93138 Compare August 14, 2017 07:28
Janez Justin added 2 commits August 22, 2017 15:24
It didn't work correctly and it interupted with overwrittign packages
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants