diff --git a/.github/workflows/fly.yml b/.github/workflows/fly.yml new file mode 100644 index 00000000..debb4731 --- /dev/null +++ b/.github/workflows/fly.yml @@ -0,0 +1,16 @@ +name: Fly Deploy +on: + push: + branches: + - main +jobs: + deploy: + name: Deploy app + runs-on: ubuntu-latest + concurrency: deploy-group + steps: + - uses: actions/checkout@v4 + - uses: superfly/flyctl-actions/setup-flyctl@master + - run: flyctl deploy --remote-only + env: + FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }} diff --git a/bruno.docs/Code/Execute Code.bru b/bruno.docs/Code/Execute Code.bru new file mode 100644 index 00000000..57c86f1f --- /dev/null +++ b/bruno.docs/Code/Execute Code.bru @@ -0,0 +1,21 @@ +meta { + name: Execute Code + type: http + seq: 1 +} + +post { + url: {{url}}/execute + body: json +} + +headers { + Content-Type: application/json +} + +body:json { + { + "language": "nodejs", + "script" : "console.log('hello world')" + } +} diff --git a/fly.toml b/fly.toml new file mode 100644 index 00000000..9e09c7b7 --- /dev/null +++ b/fly.toml @@ -0,0 +1,22 @@ +# fly.toml app configuration file generated for compilerd on 2024-02-27T08:38:17+05:30 +# +# See https://fly.io/docs/reference/configuration/ for information about how to use this file. +# + +app = 'compilerd' +primary_region = 'sin' + +[build] + +[http_service] + internal_port = 3000 + force_https = true + auto_stop_machines = true + auto_start_machines = true + min_machines_running = 0 + processes = ['app'] + +[[vm]] + memory = '1gb' + cpu_kind = 'shared' + cpus = 1