eugene-manuilov / cfpack

A CLI tool that helps to build CloudFormation template using multiple smaller templates.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Artifacts command uploads with doubled up path and backslashes for Windows 10

remiX- opened this issue · comments

Hi there,

I've been having an issue with the artifacts command for a while so decided to debug it now and found that the code uses \ instead of / due to path.join? I only had a brief look but from the docs I figured I'm doing it correctly, but it does not seem to work.

I tried using the zip compression but I download the artifact and it gives me a error saying it's invalid.

Maybe I'm doing something wrong?

Config:
image

Eg:
image

I also changed this to not join location and file as it then doubles up the path, as you can see in the screenshot above:
image

Thanks

Hi @remiX-,

sorry for the long reply. Could you please try to use the following for your artifacts?

artifacts: [
    {
        bucket: 'eu1-serverless-test-1',
        files: {
            'assets/lambda': {
                baseDir: 'assets/lambda',
                path: 'GatewayToInternetRoute.zip',
            },
        }
    }
],

This should upload the GatewayToInternetRoute.zip file from the baseDir folder to the 'assets/lambda' folder in your bucket. Let me know if it helps.

Hey @eugene-manuilov

So sorry lol, I stopped working on my project for a bit and completely forgot to check back up on here.

So it seems a little better but still adds the portion of the folder as the 'name'

image