-
-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How can I create my own layer? #37
Comments
As an update to this, it seems like we might be able to download your layer and reupload it, but since our account does not have cross-account permissions, we would have to do this in a roundabout way. If we end up being able to go that route, would we just upload this zip file to a layer ourselves? I think our preferred route is still what I posted in the original question though. Ideally, we would like to download the binarys ourselves. |
Did a test for this and I was able to use your layer but was having VPC issues with the git clone. To learn more about how the layer worked, I used awscli to download your layer and reupload it. However, it seems to work completely differently than referencing your layer directly by arn. I keep getting an error saying "git" is not recognized as a command. I could eventually fix this by into /opts/bin, but I don't understand how you are able to just access /tmp in this way and it works without issues. Do you know why your layer is being put into /tmp? |
I was able to get the git clone working just by providing a proxy config to the git command and was able to get the same functionality as your layer just by uploading the zip file exactly as it was downloaded.
I misunderstood what your code was doing. After looking into the defaults /opts/bin and /opts/lib, I realized my layer extracted to a subfolder. It looks like even unzipping and zipping without any edits causes some of the files to be corrupted due to Windows so I had some issues around there. I ended up figuring all the above out except for how you are creating the original layer. Is this the only thing you're doing to get the git files? |
I did this successfully some time ago, it's not difficult to do so. I believe the image that I used was Start the docker container with the image above and run the commands below. Here are the commands I ran, though if you execute them 1 by 1 they might not work, but regardless, you can see what the goal is from the commands:
You can now copy the layer.zip file from the container to your host (google how to do that). Now the lambda itself needs an env var: When you do If you're pushing, you need to setup the git config stuff yourself |
I love this layer. However, due to security concerns, we cannot use your layer for our production environment; similarly, we cannot simply download your layer and reupload it to a new layer on our account.
Can you please tell me how you went about creating the binary files so I can follow that process? I tried downloading them from git directly, but those files are heavily bloated compared to yours. Also, is there a way to remove the ssh binaries entirely?
The text was updated successfully, but these errors were encountered: