Skip to content

Commit

Permalink
sync example
Browse files Browse the repository at this point in the history
  • Loading branch information
fwang committed Jul 8, 2024
1 parent 8ea5b69 commit 73930e1
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ import { Resource } from "sst";
export const handler = async (event) => {
return {
statusCode: 200,
body: JSON.stringify({ event, resources: Resource.MyBucket }, null, 4),
body: JSON.stringify({ event, resources: Resource.MyBucket }, null, 2),
};
};
18 changes: 18 additions & 0 deletions examples/internal/playground/sst.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,24 @@ export default $config({
home: "aws",
};
},
console: {
autodeploy: {
target(event) {
if (
event.type === "branch" &&
event.branch === "dev" &&
event.action === "pushed"
) {
return { stage: "dev" };
}
},
workflow(context) {
context.install();
context.shell("cd examples/internal/playground && npm install");
context.deploy();
},
},
},
async run() {
const bucket = new sst.aws.Bucket("MyBucket", {
public: true,
Expand Down

0 comments on commit 73930e1

Please sign in to comment.